Skip to content

release

release #32

Workflow file for this run

name: release
on:
workflow_dispatch:
jobs:
release:
name: release
runs-on: ubuntu-latest
steps:
- name: 📁 Checkout develop branch
uses: actions/checkout@v2
with:
ref: 'develop'
fetch-depth: 0
- name: 👤 Setup Git Identity
uses: fregante/setup-git-user@v1
- name: ⬢ Setup Node
uses: actions/setup-node@v1
with:
node-version: '16'
cache: 'npm'
- name: ⚙️ Install dependencies
run: npm install --no-save
- name: ❄️ Freeze version
run: script/version freeze
- name: 🛠 Build latest JS
run: npx webpack --env production
- name: 💾 Commit updated JS to develop
run: |
git add VERSION assets
STAGE_STATIC_ASSETS=true git commit -m "Freeze version v$(cat VERSION)"
- name: Checkout main
run: |
git checkout main
- name: 𖢞 Merge to main
run: |
git merge develop
- name: Push to main
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: main
# NOTE: Temporarily keep master and main in sync, until master has been
# removed.
- name: Checkout master
run: |
git checkout master
- name: 𖢞 Merge to master
run: |
git merge develop
- name: Push to master
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: master
# NOTE: End of temporary sync section to be deleted in future.
- name: Merge back to develop
run: |
git checkout develop
git merge main
- name: Push to develop
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: develop