Merge pull request #61 from Flagsmith/fix/base-url #22
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Analyze, test and publish | |
on: | |
push: | |
tags: | |
- "*" | |
jobs: | |
analyze: | |
runs-on: ubuntu-latest | |
name: Dart Analyze | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: subosito/flutter-action@v2 | |
with: | |
flutter-version: '3.x' | |
channel: 'stable' | |
- run: flutter pub get | |
- run: flutter analyze | |
# TODO https://github.com/Flagsmith/flagsmith-flutter-client/issues/57 | |
publishing: | |
runs-on: ubuntu-latest | |
container: | |
image: google/dart:latest | |
name: Dart Publish Package | |
needs: analyze | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Setup credentials | |
run: | | |
mkdir -p ~/.pub-cache | |
cat <<EOF > ~/.pub-cache/credentials.json | |
{ | |
"accessToken":"${{ secrets.OAUTH_ACCESS_TOKEN }}", | |
"refreshToken":"${{ secrets.OAUTH_REFRESH_TOKEN }}", | |
"tokenEndpoint":"https://accounts.google.com/o/oauth2/token", | |
"scopes": [ "openid", "https://www.googleapis.com/auth/userinfo.email" ], | |
"expiration": 1649072931936 | |
} | |
EOF | |
- name: Publish package | |
run: pub publish -f |