-
Notifications
You must be signed in to change notification settings - Fork 118
44 lines (43 loc) · 1.38 KB
/
publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: Publish Alpha
on:
push:
branches:
- master
jobs:
publish_alpha:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0 # we need tags for melos, no better option ATM but check https://github.com/actions/checkout/issues/701
- name: Install Flutter
uses: subosito/flutter-action@v2
with:
channel: beta
- name: Activate melos
run: |
echo "$HOME/.pub-cache/bin" >> $GITHUB_PATH
dart pub global activate melos
- name: Bootstrap melos
run: melos bs
- name: Configure git user
run: |
git config user.name github-actions
git config user.email [email protected]
- run: melos version --yes -p
- name: Setup Pub Credentials
shell: bash
env:
CREDENTIALS_JSON: ${{ secrets.CREDENTIALS_JSON }}
run: |
mkdir -p $XDG_CONFIG_HOME/dart/
echo $CREDENTIALS_JSON > $XDG_CONFIG_HOME/dart/pub-credentials.json
- run: melos publish --yes --dry-run --ignore="*pokemon*"
- run: melos publish --yes --no-dry-run --ignore="*pokemon*"
continue-on-error: true
- name: Push back version bumps
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: master
tags: true