Update AutoPublish workflow to enable auto-merge of pull-requests #1661
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Background tasks | |
permissions: | |
pull-requests: write | |
contents: read | |
on: | |
pull_request_target: | |
jobs: | |
upload: | |
if: github.repository_owner == 'MicrosoftDocs' | |
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/ |