@@ -45,20 +45,11 @@ jobs:
4545 )
4646 runs-on : ubuntu-latest
4747 steps :
48- - name : Generate GitHub App token
49- id : app-token
50- uses : actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1 # v3.2.0
51- with :
52- app-id : ${{ secrets.DOCS_BOT_APP_ID }}
53- private-key : ${{ secrets.DOCS_BOT_APP_PRIVATE_KEY }}
54- owner : github
55- repositories : docs-internal,docs-content,docs-engineering
56-
5748 - name : Resolve PR data
5849 id : resolve_pr
5950 uses : actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
6051 with :
61- github-token : ${{ steps.app-token.outputs.token }}
52+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
6253 script : |
6354 let pr;
6455 if (context.eventName === 'workflow_dispatch') {
8677 id : check_team
8778 uses : actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
8879 with :
89- github-token : ${{ steps.app-token.outputs.token }}
80+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
9081 script : |
9182 const author = '${{ steps.resolve_pr.outputs.pr_author }}';
9283
@@ -124,7 +115,7 @@ jobs:
124115 env :
125116 PR_BODY : ${{ steps.resolve_pr.outputs.pr_body }}
126117 with :
127- github-token : ${{ steps.app-token.outputs.token }}
118+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
128119 script : |
129120 const body = process.env.PR_BODY || '';
130121
@@ -159,7 +150,7 @@ jobs:
159150 id : check_parent
160151 uses : actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
161152 with :
162- github-token : ${{ steps.app-token.outputs.token }}
153+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
163154 script : |
164155 const issueNumber = parseInt('${{ steps.extract_issue.outputs.issue_number }}', 10);
165156
@@ -240,7 +231,7 @@ jobs:
240231 PR_BODY : ${{ steps.resolve_pr.outputs.pr_body }}
241232 PR_URL : ${{ steps.resolve_pr.outputs.pr_url }}
242233 with :
243- github-token : ${{ steps.app-token.outputs.token }}
234+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
244235 script : |
245236 const prNumber = parseInt('${{ steps.resolve_pr.outputs.pr_number }}', 10);
246237 const prAuthor = '${{ steps.resolve_pr.outputs.pr_author }}';
@@ -281,7 +272,7 @@ jobs:
281272 id : check_existing
282273 uses : actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
283274 with :
284- github-token : ${{ steps.app-token.outputs.token }}
275+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
285276 script : |
286277 const branchName = `changelog-agent-${{ steps.resolve_pr.outputs.pr_number }}`;
287278 const { data: pulls } = await github.rest.pulls.list({
@@ -304,7 +295,7 @@ jobs:
304295 id : read_examples
305296 uses : actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
306297 with :
307- github-token : ${{ steps.app-token.outputs.token }}
298+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
308299 script : |
309300 // Fetch changelog-internal.md from docs-content
310301 const { data } = await github.rest.repos.getContent({
@@ -474,7 +465,7 @@ jobs:
474465 PARENT_AUTHOR : ${{ steps.check_parent.outputs.parent_author }}
475466 PARENT_ASSIGNEES : ${{ steps.check_parent.outputs.parent_assignees }}
476467 with :
477- github-token : ${{ steps.app-token.outputs.token }}
468+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
478469 script : |
479470 const branchName = `changelog-agent-${{ steps.resolve_pr.outputs.pr_number }}`;
480471 const filePath = 'docs-content-docs/docs-content-workflows/changelog-internal.md';
@@ -635,7 +626,7 @@ jobs:
635626 PARENT_AUTHOR : ${{ steps.check_parent.outputs.parent_author }}
636627 PARENT_ASSIGNEES : ${{ steps.check_parent.outputs.parent_assignees }}
637628 with :
638- github-token : ${{ steps.app-token.outputs.token }}
629+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
639630 script : |
640631 const author = process.env.PR_AUTHOR;
641632 const changelogPrUrl = process.env.CHANGELOG_PR_URL;
@@ -730,7 +721,7 @@ jobs:
730721 if : steps.create_pr.outputs.changelog_pr_url != '' && inputs.dry_run != true
731722 uses : actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
732723 with :
733- github-token : ${{ steps.app-token.outputs.token }}
724+ github-token : ${{ secrets.DOCS_BOT_PAT_BASE }}
734725 script : |
735726 const changelogPrUrl = '${{ steps.create_pr.outputs.changelog_pr_url }}';
736727 await github.rest.issues.createComment({
@@ -753,4 +744,4 @@ jobs:
753744 - uses : ./.github/actions/create-workflow-failure-issue
754745 if : ${{ failure() && github.event_name != 'workflow_dispatch' }}
755746 with :
756- token : ${{ steps.app-token.outputs.token }}
747+ token : ${{ secrets.DOCS_BOT_PAT_BASE }}
0 commit comments