Skip to content

Commit b0b66d2

Browse files
committed
build: tweak permissions and use fine-grained PAT
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: na - task: lint_typescript_tests status: na - task: lint_license_headers status: passed --- --- type: pre_push_report description: Results of running various checks prior to pushing changes. report: - task: run_javascript_examples status: na - task: run_c_examples status: na - task: run_cpp_examples status: na - task: run_javascript_readme_examples status: na - task: run_c_benchmarks status: na - task: run_cpp_benchmarks status: na - task: run_fortran_benchmarks status: na - task: run_javascript_benchmarks status: na - task: run_julia_benchmarks status: na - task: run_python_benchmarks status: na - task: run_r_benchmarks status: na - task: run_javascript_tests status: na ---
1 parent 02b9077 commit b0b66d2

11 files changed

+40
-14
lines changed

.github/workflows/do_not_merge.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,7 @@ jobs:
4343

4444
# Define job permissions:
4545
permissions:
46-
contents: read
47-
pull-requests: write
46+
pull-requests: read
4847

4948
# Define the type of virtual host machine:
5049
runs-on: ubuntu-latest

.github/workflows/first_time_greeting.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ on: [pull_request_target, issues]
2424

2525
# Global permissions:
2626
permissions:
27-
# Allow read-only access to the repository contents:
28-
contents: read
27+
# Do not give the workflow any permissions:
28+
contents: none
2929

3030
# Workflow jobs:
3131
jobs:
@@ -47,7 +47,7 @@ jobs:
4747
# Pin action to full length commit SHA
4848
uses: actions/first-interaction@34f15e814fe48ac9312ccf29db4e74fa767cbab7 # v1.3.0
4949
with:
50-
repo-token: ${{ secrets.CHATBOT_GITHUB_TOKEN }}
50+
repo-token: ${{ secrets.STDLIB_BOT_FGPAT_PR_WRITE }}
5151
issue-message: |
5252
:wave: Hi there! :wave:
5353

.github/workflows/make.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,9 @@ jobs:
6464

6565
# Specify whether to download Git-LFS files:
6666
lfs: false
67+
68+
# Avoid storing GitHub token in local Git configuration:
69+
persist-credentials: false
6770
timeout-minutes: 10
6871

6972
# Install Node.js:

.github/workflows/markdown_equations.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,9 @@ jobs:
6464

6565
# Specify whether to download Git-LFS files:
6666
lfs: false
67+
68+
# Avoid storing GitHub token in local Git configuration:
69+
persist-credentials: false
6770
timeout-minutes: 10
6871

6972
# Install Node.js:
@@ -103,7 +106,6 @@ jobs:
103106
git_user_signingkey: true
104107
git_commit_gpgsign: true
105108

106-
107109
# Generate list of changed Markdown files:
108110
- name: 'Find changed Markdown files'
109111
run: |
@@ -161,7 +163,7 @@ jobs:
161163
commit-message: 'docs: update Markdown equation elements'
162164
committer: 'stdlib-bot <82920195+stdlib-bot@users.noreply.github.com>'
163165
signoff: true
164-
token: ${{ secrets.PULL_REQUEST_TOKEN }}
166+
token: ${{ secrets.STDLIB_BOT_FGPAT_PR_WRITE }}
165167
labels: |
166168
documentation
167169
automated-pr

.github/workflows/markdown_links.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,9 @@ jobs:
7676

7777
# Specify whether to download Git-LFS files:
7878
lfs: false
79+
80+
# Avoid storing GitHub token in local Git configuration:
81+
persist-credentials: false
7982
timeout-minutes: 10
8083

8184
# Initialize log files:

.github/workflows/markdown_pkg_urls.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,10 @@ jobs:
7070

7171
# Specify whether to download Git-LFS files:
7272
lfs: false
73+
74+
# Avoid storing GitHub token in local Git configuration:
75+
persist-credentials: false
76+
7377
timeout-minutes: 10
7478

7579
# Install Node.js:
@@ -131,7 +135,7 @@ jobs:
131135
fi
132136
timeout-minutes: 10
133137

134-
# Create a pull request with the changes:
138+
# Create a pull request with the changes:
135139
- name: 'Create pull request'
136140
id: cpr
137141
if: steps.update-markdown-pkg-urls.outputs.changed == 'true'
@@ -147,7 +151,7 @@ jobs:
147151
commit-message: 'docs: update Markdown stdlib package URLs'
148152
committer: 'stdlib-bot <82920195+stdlib-bot@users.noreply.github.com>'
149153
signoff: true
150-
token: ${{ secrets.PULL_REQUEST_TOKEN }}
154+
token: ${{ secrets.STDLIB_BOT_FGPAT_PR_WRITE }}
151155
labels: |
152156
documentation
153157
automated-pr

.github/workflows/markdown_related_packages.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,9 @@ jobs:
6868

6969
# Specify whether to download Git-LFS files:
7070
lfs: false
71+
72+
# Avoid storing GitHub token in local Git configuration:
73+
persist-credentials: false
7174
timeout-minutes: 10
7275

7376
# Install Node.js:
@@ -159,7 +162,7 @@ jobs:
159162
commit-message: 'docs: update related packages sections'
160163
committer: 'stdlib-bot <82920195+stdlib-bot@users.noreply.github.com>'
161164
signoff: true
162-
token: ${{ secrets.PULL_REQUEST_TOKEN }}
165+
token: ${{ secrets.STDLIB_BOT_FGPAT_PR_WRITE }}
163166
labels: |
164167
documentation
165168
automated-pr

.github/workflows/markdown_src_attributes.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ name: markdown_src_attributes
2323
on:
2424
schedule:
2525
# Run the workflow once a month on the 1st day of every month:
26-
- cron: "0 0 1 * *"
26+
- cron: '0 0 1 * *'
2727

2828
# Allow the workflow to be manually run:
2929
workflow_dispatch:
@@ -73,6 +73,9 @@ jobs:
7373

7474
# Specify whether to download Git-LFS files:
7575
lfs: false
76+
77+
# Avoid storing GitHub token in local Git configuration:
78+
persist-credentials: false
7679
timeout-minutes: 10
7780

7881
# Initialize log files:

.github/workflows/markdown_tocs.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,9 @@ jobs:
6464

6565
# Specify whether to download Git-LFS files:
6666
lfs: false
67+
68+
# Avoid storing GitHub token in local Git configuration:
69+
persist-credentials: false
6770
timeout-minutes: 10
6871

6972
# Install Node.js:
@@ -129,7 +132,7 @@ jobs:
129132
commit-message: 'docs: update namespace table of contents'
130133
signoff: true
131134
committer: 'stdlib-bot <82920195+stdlib-bot@users.noreply.github.com>'
132-
token: ${{ secrets.PULL_REQUEST_TOKEN }}
135+
token: ${{ secrets.STDLIB_BOT_FGPAT_PR_WRITE }}
133136
labels: |
134137
documentation
135138
automated-pr

.github/workflows/namespace_declarations.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,9 @@ jobs:
6464

6565
# Specify whether to download Git-LFS files:
6666
lfs: false
67+
68+
# Avoid storing GitHub token in local Git configuration:
69+
persist-credentials: false
6770
timeout-minutes: 10
6871

6972
# Install Node.js:
@@ -124,7 +127,7 @@ jobs:
124127
commit-message: 'feat: update namespace TypeScript declarations'
125128
committer: 'stdlib-bot <82920195+stdlib-bot@users.noreply.github.com>'
126129
signoff: true
127-
token: ${{ secrets.PULL_REQUEST_TOKEN }}
130+
token: ${{ secrets.STDLIB_BOT_FGPAT_PR_WRITE }}
128131
labels: |
129132
documentation
130133
automated-pr

0 commit comments

Comments
 (0)