Skip to content

Commit

Permalink
Fix publish action (close #38)
Browse files Browse the repository at this point in the history
  • Loading branch information
matus-tomlein committed Feb 21, 2024
1 parent 4f754a0 commit 9896ad6
Showing 1 changed file with 4 additions and 20 deletions.
24 changes: 4 additions & 20 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Publish package to pub.dev and make a GitHub release
on:
push:
tags:
- '*.*.*'
- '[0-9]+.[0-9]+.[0-9]+*'

jobs:
test:
Expand Down Expand Up @@ -62,25 +62,9 @@ jobs:
publish_pubdev:
needs: ["test", "version_check"]
runs-on: ubuntu-latest
container:
image: google/dart:latest
steps:
- uses: actions/checkout@v1
- name: Setup credentials
run: |
mkdir -p ~/.pub-cache
cat <<EOF > ~/.pub-cache/credentials.json
{
"accessToken":"${{ secrets.ACCESS_TOKEN }}",
"refreshToken":"${{ secrets.REFRESH_TOKEN }}",
"tokenEndpoint":"https://accounts.google.com/o/oauth2/token",
"scopes": [ "openid", "https://www.googleapis.com/auth/userinfo.email" ],
"expiration": 1643122520446
}
EOF
- name: Publish package
run: pub publish -f
permissions:
id-token: write
uses: dart-lang/setup-dart/.github/workflows/publish.yml@v1

release:
needs: ["test", "publish_pubdev", "version_check"]
Expand Down

0 comments on commit 9896ad6

Please sign in to comment.