2022-11-29 23:50:31 +00:00
|
|
|
# Runs on releases
|
|
|
|
|
|
|
|
name: Publish release notes
|
|
|
|
on:
|
|
|
|
release:
|
|
|
|
types: [ published ]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
|
|
|
|
stable:
|
|
|
|
runs-on: ubuntu-latest
|
2022-12-21 12:00:23 +00:00
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
2022-11-29 23:50:31 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout Code
|
2023-10-24 22:18:53 +00:00
|
|
|
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # pin@v4.1.1
|
2022-11-29 23:50:31 +00:00
|
|
|
- name: Version Check
|
|
|
|
run: |
|
|
|
|
pip install requests
|
|
|
|
python3 ci/version_check.py
|
|
|
|
- name: Push to Stable Branch
|
2023-10-24 22:18:53 +00:00
|
|
|
uses: ad-m/github-push-action@d91a481090679876dfc4178fef17f286781251df # pin@v0.8.0
|
2022-11-29 23:50:31 +00:00
|
|
|
if: env.stable_release == 'true'
|
|
|
|
with:
|
|
|
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
branch: stable
|
|
|
|
force: true
|
2023-07-20 00:12:08 +00:00
|
|
|
|
|
|
|
publish-build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2023-10-24 22:18:53 +00:00
|
|
|
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # pin@v4.1.1
|
2023-07-20 00:12:08 +00:00
|
|
|
- name: Environment Setup
|
|
|
|
uses: ./.github/actions/setup
|
|
|
|
with:
|
|
|
|
npm: true
|
|
|
|
- name: Install dependencies
|
|
|
|
run: cd src/frontend && yarn install
|
|
|
|
- name: Build frontend
|
|
|
|
run: cd src/frontend && npm run build
|
|
|
|
- name: Zip frontend
|
|
|
|
run: |
|
|
|
|
cd InvenTree/web/static/web
|
|
|
|
zip -r ../frontend-build.zip *
|
2023-10-24 22:18:53 +00:00
|
|
|
- uses: svenstaro/upload-release-action@1beeb572c19a9242f4361f4cee78f8e0d9aec5df # pin@2.7.0
|
2023-07-20 00:12:08 +00:00
|
|
|
with:
|
|
|
|
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
file: InvenTree/web/static/frontend-build.zip
|
|
|
|
asset_name: frontend-build.zip
|
|
|
|
tag: ${{ github.ref }}
|
|
|
|
overwrite: true
|