From 510a7ad8243218905eac8fc7fecfe8dcf4fbefd5 Mon Sep 17 00:00:00 2001 From: Evie Grimshaw <116228522+EvieGrimshaw@users.noreply.github.com> Date: Tue, 13 Aug 2024 07:59:47 -0700 Subject: [PATCH 1/3] Learn Editor: Update New-CsTeamsWorkLocationDetectionPolicy.md --- teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md b/teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md index 8b7646f1a0..e7eb02743b 100644 --- a/teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md +++ b/teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md @@ -11,7 +11,7 @@ author: artemiykozlov # New-CsTeamsWorkLocationDetectionPolicy ## SYNOPSIS -This cmdlet is used to create a new instance of the TeamsWorkLocationDetectionPolicy. +This cmdlet is used to create a new instance of the TeamsWorkLocationDetectionPolicy. The end user experience utilizing this policy is currently under development and has not been made generally available. You can see updates on when it will be generally available at [Microsoft 365 Roadmap | Microsoft 365](https://www.microsoft.com/en-us/microsoft-365/roadmap?msockid=287ab43847c06d0008cca05b46076c18&filters=&searchterms=automatically%2Cset%2Cwork%2Clocation"https://www.microsoft.com/en-us/microsoft-365/roadmap?msockid=287ab43847c06d0008cca05b46076c18&filters=&searchterms=automatically%2cset%2cwork%2clocation"). ## SYNTAX From a04f0ae491658e837c20b9524d6162d4cf104cc9 Mon Sep 17 00:00:00 2001 From: jacktremper <149415765+jacktremper@users.noreply.github.com> Date: Wed, 21 Aug 2024 11:10:04 -0700 Subject: [PATCH 2/3] Update New-CsTeamsWorkLocationDetectionPolicy.md --- teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md b/teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md index e7eb02743b..b4f16b7404 100644 --- a/teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md +++ b/teams/teams-ps/teams/New-CsTeamsWorkLocationDetectionPolicy.md @@ -11,7 +11,7 @@ author: artemiykozlov # New-CsTeamsWorkLocationDetectionPolicy ## SYNOPSIS -This cmdlet is used to create a new instance of the TeamsWorkLocationDetectionPolicy. The end user experience utilizing this policy is currently under development and has not been made generally available. You can see updates on when it will be generally available at [Microsoft 365 Roadmap | Microsoft 365](https://www.microsoft.com/en-us/microsoft-365/roadmap?msockid=287ab43847c06d0008cca05b46076c18&filters=&searchterms=automatically%2Cset%2Cwork%2Clocation"https://www.microsoft.com/en-us/microsoft-365/roadmap?msockid=287ab43847c06d0008cca05b46076c18&filters=&searchterms=automatically%2cset%2cwork%2clocation"). +This cmdlet is used to create a new instance of the TeamsWorkLocationDetectionPolicy. The end user experience utilizing this policy is currently under development and has not been made generally available. You can see updates on when it will be generally available at [Microsoft 365 Roadmap | Microsoft 365](https://www.microsoft.com/en-us/microsoft-365/roadmap?msockid=287ab43847c06d0008cca05b46076c18&filters=&searchterms=automatically%2Cset%2Cwork%2Clocation). ## SYNTAX From 19c9b28cbeebeedf54b23ada76caf0aec80a18f7 Mon Sep 17 00:00:00 2001 From: shdyas Date: Wed, 21 Aug 2024 13:47:21 -0700 Subject: [PATCH 3/3] Migrate workflows from microsoft-365-docs-pr --- .github/workflows/AutoLabelAssign.yml | 35 +++++++++++++++++++ .../workflows/AutoLabelMsftContributor.yml | 34 ++++++++++++++++++ .github/workflows/BackgroundTasks.yml | 26 ++++++++++++++ .github/workflows/LiveMergeCheck.yml | 19 ++++++++++ .github/workflows/PrFileCount.yml | 19 ++++++++++ .github/workflows/ProtectedFiles.yml | 17 +++++++++ 6 files changed, 150 insertions(+) create mode 100644 .github/workflows/AutoLabelAssign.yml create mode 100644 .github/workflows/AutoLabelMsftContributor.yml create mode 100644 .github/workflows/BackgroundTasks.yml create mode 100644 .github/workflows/LiveMergeCheck.yml create mode 100644 .github/workflows/PrFileCount.yml create mode 100644 .github/workflows/ProtectedFiles.yml diff --git a/.github/workflows/AutoLabelAssign.yml b/.github/workflows/AutoLabelAssign.yml new file mode 100644 index 0000000000..1a30efad7c --- /dev/null +++ b/.github/workflows/AutoLabelAssign.yml @@ -0,0 +1,35 @@ +name: Assign and label PR + +permissions: + pull-requests: write + contents: read + actions: read + +on: + workflow_run: + workflows: [Background tasks] + types: + - completed + +jobs: + download-payload: + name: Download and extract payload artifact + uses: MicrosoftDocs/microsoft-365-docs/.github/workflows/Shared-ExtractPayload.yml@workflows-prod + with: + WorkflowId: ${{ github.event.workflow_run.id }} + OrgRepo: ${{ github.repository }} + secrets: + AccessToken: ${{ secrets.GITHUB_TOKEN }} + + label-assign: + name: Run assign and label + needs: [download-payload] + uses: MicrosoftDocs/microsoft-365-docs/.github/workflows/Shared-AutoLabelAssign.yml@workflows-prod + with: + PayloadJson: ${{ needs.download-payload.outputs.WorkflowPayload }} + AutoAssignUsers: 1 + AutoLabel: 1 + ExcludedUserList: '["user1", "user2"]' + ExcludedBranchList: '["branch1", "branch2"]' + secrets: + AccessToken: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/AutoLabelMsftContributor.yml b/.github/workflows/AutoLabelMsftContributor.yml new file mode 100644 index 0000000000..7058a420cf --- /dev/null +++ b/.github/workflows/AutoLabelMsftContributor.yml @@ -0,0 +1,34 @@ +name: Auto label Microsoft contributors + +permissions: + pull-requests: write + contents: read + actions: read + +on: + workflow_run: + workflows: [Background tasks] + types: + - completed + +jobs: + download-payload: + if: github.repository_visibility == 'public' + name: Download and extract payload artifact + uses: MicrosoftDocs/microsoft-365-docs/.github/workflows/Shared-ExtractPayload.yml@workflows-prod + with: + WorkflowId: ${{ github.event.workflow_run.id }} + OrgRepo: ${{ github.repository }} + secrets: + AccessToken: ${{ secrets.GITHUB_TOKEN }} + + label-msft: + name: Label Microsoft contributors + if: github.repository_visibility == 'public' + needs: [download-payload] + uses: MicrosoftDocs/microsoft-365-docs/.github/workflows/Shared-AutoLabelMsftContributor.yml@workflows-prod + with: + PayloadJson: ${{ needs.download-payload.outputs.WorkflowPayload }} + secrets: + AccessToken: ${{ secrets.GITHUB_TOKEN }} + TeamReadAccessToken: ${{ secrets.ORG_READTEAMS_TOKEN }} diff --git a/.github/workflows/BackgroundTasks.yml b/.github/workflows/BackgroundTasks.yml new file mode 100644 index 0000000000..c0389bb252 --- /dev/null +++ b/.github/workflows/BackgroundTasks.yml @@ -0,0 +1,26 @@ +name: Background tasks + +permissions: + pull-requests: write + contents: read + +on: + pull_request_target: + +jobs: + upload: + runs-on: ubuntu-latest + + steps: + - name: Save payload data + env: + PayloadJson: ${{ toJSON(github) }} + AccessToken: ${{ github.token }} + run: | + mkdir -p ./pr + echo $PayloadJson > ./pr/PayloadJson.json + sed -i -e "s/$AccessToken/XYZ/g" ./pr/PayloadJson.json + - uses: actions/upload-artifact@v4 + with: + name: PayloadJson + path: pr/ diff --git a/.github/workflows/LiveMergeCheck.yml b/.github/workflows/LiveMergeCheck.yml new file mode 100644 index 0000000000..56b79b4813 --- /dev/null +++ b/.github/workflows/LiveMergeCheck.yml @@ -0,0 +1,19 @@ +name: PR can merge into branch + +permissions: + pull-requests: write + statuses: write + contents: read + +on: + pull_request_target: + types: [opened, reopened, synchronize, edited] + +jobs: + + live-merge: + uses: MicrosoftDocs/microsoft-365-docs/.github/workflows/Shared-LiveMergeCheck.yml@workflows-prod + with: + PayloadJson: ${{ toJSON(github) }} + secrets: + AccessToken: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/PrFileCount.yml b/.github/workflows/PrFileCount.yml new file mode 100644 index 0000000000..95fcf5e1ed --- /dev/null +++ b/.github/workflows/PrFileCount.yml @@ -0,0 +1,19 @@ +name: PR file count less than limit + +permissions: + pull-requests: write + statuses: write + contents: read + +on: + pull_request_target: + types: [opened, reopened, synchronize, labeled, unlabeled, edited] + +jobs: + + file-count: + uses: MicrosoftDocs/microsoft-365-docs/.github/workflows/Shared-PrFileCount.yml@workflows-prod + with: + PayloadJson: ${{ toJSON(github) }} + secrets: + AccessToken: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/ProtectedFiles.yml b/.github/workflows/ProtectedFiles.yml new file mode 100644 index 0000000000..769cd0aa14 --- /dev/null +++ b/.github/workflows/ProtectedFiles.yml @@ -0,0 +1,17 @@ +name: PR has no protected files + +permissions: + pull-requests: write + statuses: write + contents: read + +on: [pull_request_target] + +jobs: + + protected-files: + uses: MicrosoftDocs/microsoft-365-docs/.github/workflows/Shared-ProtectedFiles.yml@workflows-prod + with: + PayloadJson: ${{ toJSON(github) }} + secrets: + AccessToken: ${{ secrets.GITHUB_TOKEN }}