Skip to content
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

Tighten actions versions and permissions #1342

Merged
merged 1 commit into from
Feb 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 5 additions & 3 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,17 @@ on:
tags:
- '[0-9]+.[0-9]+.[0-9]+*'

permissions: read-all

jobs:
publish:
permissions:
id-token: write # This is required for requesting the JWT
id-token: write # Required for authentication using OIDC
runs-on: ubuntu-latest
environment: pub-dev
steps:
- uses: actions/checkout@v4
- uses: isoos/setup-dart@oidc-token
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- uses: dart-lang/setup-dart@fedb1266e91cf51be2fdb382869461a434b920a3
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OMG, yes!

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch!

- name: Install dependencies
run: dart pub get
- name: Analyze
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/test-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ on:
env:
PUB_ENVIRONMENT: bot.github

permissions: read-all

jobs:
# Check code formatting and static analysis on a single OS (linux).
analyze:
Expand All @@ -21,7 +23,7 @@ jobs:
matrix:
sdk: [3.2.0]
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- uses: dart-lang/setup-dart@fedb1266e91cf51be2fdb382869461a434b920a3
with:
sdk: ${{ matrix.sdk }}
Expand Down Expand Up @@ -50,7 +52,7 @@ jobs:
sdk: [3.2.0]
flutter: [3.16.0]
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- uses: dart-lang/setup-dart@fedb1266e91cf51be2fdb382869461a434b920a3
with:
sdk: ${{ matrix.sdk }}
Expand Down Expand Up @@ -79,11 +81,11 @@ jobs:
strategy:
fail-fast: false
steps:
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
- uses: dart-lang/setup-dart@fedb1266e91cf51be2fdb382869461a434b920a3
with:
sdk: '3.3.0-120.0.dev' # TODO: switch back to rolling 'dev' channel after it gets updated.
- uses: subosito/flutter-action@cc97e1648fff6ca5cc647fa67f47e70f7895510b
- uses: subosito/flutter-action@2783a3f08e1baf891508463f8c6653c258246225
with:
# flutter-version: '3.4.0-34.1.pre'
channel: 'master' # TODO: switch back to rolling 'dev' channel after it gets updated.
Expand Down