-
Notifications
You must be signed in to change notification settings - Fork 0
Update 8hobbies/workflows digest to d1e85a0 #307
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -19,6 +19,6 @@ | |
| tags: ["v*"] | ||
| jobs: | ||
| build: | ||
| uses: 8hobbies/workflows/.github/workflows/npm-publish.yml@b912c36872c2ee7c67d5a8a8478382301e9e3060 | ||
| uses: 8hobbies/workflows/.github/workflows/npm-publish.yml@d1e85a08791c06db486a7943658d5090c27339db | ||
| secrets: | ||
| npm-auth-token: ${{ secrets.NPM_TOKEN }} | ||
Check warningCode scanning / CodeQL Workflow does not contain permissions Medium
Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {}
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -22,4 +22,4 @@ | |||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| jobs: | ||||||||||||||||||||||||||||||||
| test: | ||||||||||||||||||||||||||||||||
| uses: 8hobbies/workflows/.github/workflows/npm-runtime.yml@b912c36872c2ee7c67d5a8a8478382301e9e3060 | ||||||||||||||||||||||||||||||||
| uses: 8hobbies/workflows/.github/workflows/npm-runtime.yml@d1e85a08791c06db486a7943658d5090c27339db | ||||||||||||||||||||||||||||||||
Check warningCode scanning / CodeQL Workflow does not contain permissions Medium
Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {}
Copilot AutofixAI about 2 months ago In general, the fix is to explicitly declare For this file, the most targeted fix without changing functionality is to add a permissions:
contents: readThis ensures the top-level workflow’s Concretely:
Suggested changeset
1
.github/workflows/runtime.yml
Copilot is powered by AI and may make mistakes. Always verify output.
Refresh and try again.
|
||||||||||||||||||||||||||||||||
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium
Copilot Autofix
AI about 2 months ago
In general, this problem is fixed by explicitly adding a
permissionsblock either at the root of the workflow (applies to all jobs without their own permissions) or at the specific job level, and setting the least privileges needed. For a lint workflow that only needs to read source code and dependencies,contents: read(and optionally other read-only scopes likepackages: readif required) is typically sufficient.The minimal, least-privilege change here is to add a top-level
permissions:block below theon:section in.github/workflows/lint.yml. This will apply to thelintjob (which uses a reusable workflow) unless that reusable workflow further restricts permissions. No existing functionality in this file changes, because the job definition (uses: 8hobbies/workflows/.github/workflows/npm-lint.yml@...) remains untouched; we only constrain theGITHUB_TOKEN. Concretely, update.github/workflows/lint.ymlby inserting:at the root level, aligned with
name,on, andjobs. No imports, methods, or additional definitions are required beyond that YAML addition.