1- name : Release
1+ name : Release and deploy to IPFS
22on :
3- schedule :
4- - cron : ' 0 10 * * 1-4' # run 12:00 UTC+2 Monday-Thursday
3+ pull_request :
4+ types :
5+ - closed
6+
57 workflow_dispatch :
68 inputs :
79 debug_enabled :
1214
1315jobs :
1416 tag :
17+ if : github.event.pull_request.merged == true
1518 runs-on : ubuntu-latest
1619 outputs :
1720 new_tag : ${{ steps.github-tag-action.outputs.new_tag }}
@@ -26,10 +29,12 @@ jobs:
2629 # new_tag is only set when there are new semver commits
2730 # on the release branch
2831 release_branches : release
29- default_bump : patch
32+ # bumps have to be set explicitly
33+ default_bump : false
3034
3135 release :
3236 needs : tag
37+ environment : production
3338 # only release when there is a new tag
3439 if : ${{ needs.tag.outputs.new_tag != null }}
3540 runs-on : ubuntu-latest
3944 - name : Add .env files
4045 run : echo ${{secrets.ENV_WEBSITE_BASE64}} | base64 -d > ./packages/website/.env
4146
42- - name : Setup tmate session
43- uses : mxschmitt/action-tmate@v3
44- if : ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}
45- timeout-minutes : 15
46- with :
47- limit-access-to-actor : true
48-
4947 - name : Build
5048 env :
5149 CI : true
5553 yarn workspace @package/dump-pow-website run build
5654 yarn workspace @package/dump-pow-website run export
5755
56+ - name : Setup tmate session
57+ uses : mxschmitt/action-tmate@v3
58+ # only start the session when enable via manual workflow trigger and the previous step failed
59+ if : ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled && ${{ failure() }}}}
60+ timeout-minutes : 15
61+ with :
62+ limit-access-to-actor : true
63+
5864 -
uses :
aquiladev/[email protected] 5965 id : upload
6066 with :
67+ path : ./packages/website/out
6168 service : pinata
6269 pinataKey : ${{ secrets.PINATA_KEY }}
6370 pinataSecret : ${{ secrets.PINATA_SECRET }}
0 commit comments