Skip to content

Commit 44e795d

Browse files
authored
use leancodepl/mobile-tool for releasing (#712)
1 parent 03c28c6 commit 44e795d

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

.github/workflows/publish.yaml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,35 @@ jobs:
1717
with:
1818
sdk: 2.17.0
1919

20+
- name: Install mobile-tools
21+
uses: actions/checkout@v3
22+
with:
23+
repository: leancodepl/mobile-tools
24+
path: mobile-tools
25+
26+
- name: Add mobile-tools to PATH
27+
run: |
28+
echo $GITHUB_WORKSPACE/mobile-tools/bin >> $GITHUB_PATH
29+
2030
- name: Download pub.dev credentials
2131
env:
2232
CREDENTIALS: ${{ secrets.PUB_DEV_CREDENTIALS }}
2333
run: |
2434
mkdir -p ~/.pub-cache
2535
echo $CREDENTIALS > ~/.pub-cache/credentials.json
2636
37+
- name: Set version data
38+
run: |
39+
tag=${{ github.ref_name }}
40+
echo "RELEASE_NOTES=$(link_changelog $tag)" >> $GITHUB_ENV
41+
echo "IS_PRERELEASE=$(is_prerelease $tag)" >> $GITHUB_ENV
42+
2743
- name: Publish
2844
run: dart pub publish -f
45+
46+
- name: Create release
47+
uses: softprops/action-gh-release@v1
48+
with:
49+
name: ${{ github.ref_name }}
50+
body: "[See changelog on pub.dev](${{ env.RELEASE_NOTES }})"
51+
prerelease: ${{ env.IS_PRERELEASE }}

0 commit comments

Comments
 (0)