Skip to content

Commit 0509d19

Browse files
authored
Fix failed scorecard analysis (#189)
1 parent 5d5c81a commit 0509d19

File tree

1 file changed

+12
-14
lines changed

1 file changed

+12
-14
lines changed

.github/workflows/scorecard.yml

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ on:
1010
# To guarantee Maintained check is occasionally updated. See
1111
# https://github.com/ossf/scorecard/blob/main/docs/checks.md#maintained
1212
schedule:
13-
- cron: '15 21 * * 3'
13+
- cron: '41 3 * * 3'
1414
push:
1515
branches: [ "main" ]
1616

17-
# Declare default permissions as read only.
18-
permissions: read-all
17+
permissions:
18+
contents: read
1919

2020
jobs:
2121
analysis:
@@ -26,9 +26,8 @@ jobs:
2626
security-events: write
2727
# Needed to publish results and get a badge (see publish_results below).
2828
id-token: write
29-
# Uncomment the permissions below if installing in a private repository.
30-
# contents: read
31-
# actions: read
29+
# Needed to check out code
30+
contents: read
3231

3332
steps:
3433
- name: "Checkout code"
@@ -41,13 +40,11 @@ jobs:
4140
with:
4241
results_file: results.sarif
4342
results_format: sarif
44-
# (Optional) Read-only PAT token. Uncomment the `repo_token` line below if:
43+
# (Optional) "write" PAT token. Uncomment the `repo_token` line below if:
4544
# - you want to enable the Branch-Protection check on a *public* repository, or
46-
# - you are installing Scorecards on a *private* repository
47-
# To create the PAT, follow the steps in https://github.com/ossf/scorecard-action#authentication-with-pat.
48-
# TODO(mhutchinson): Instead of this, we should use rulesets and then permissions are not needed:
49-
# https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/managing-rulesets/about-rulesets
50-
repo_token: ${{ secrets.TD_SCORECARD_READ_TOKEN }}
45+
# - you are installing Scorecard on a *private* repository
46+
# To create the PAT, follow the steps in https://github.com/ossf/scorecard-action?tab=readme-ov-file#authentication-with-fine-grained-pat-optional.
47+
# repo_token: ${{ secrets.SCORECARD_TOKEN }}
5148

5249
# Public repositories:
5350
# - Publish results to OpenSSF REST API for easy access by consumers
@@ -67,8 +64,9 @@ jobs:
6764
path: results.sarif
6865
retention-days: 5
6966

70-
# Upload the results to GitHub's code scanning dashboard.
67+
# Upload the results to GitHub's code scanning dashboard (optional).
68+
# Commenting out will disable upload of results to your repo's Code Scanning dashboard
7169
- name: "Upload to code-scanning"
72-
uses: github/codeql-action/upload-sarif@76621b61decf072c1cee8dd1ce2d2a82d33c17ed # v3.29.5
70+
uses: github/codeql-action/upload-sarif@76621b61decf072c1cee8dd1ce2d2a82d33c17ed # v3.29.8
7371
with:
7472
sarif_file: results.sarif

0 commit comments

Comments
 (0)