mirror of
https://github.com/jxxghp/MoviePilot-Frontend.git
synced 2026-09-05 15:36:49 +08:00
auto build
This commit is contained in:
+20
-15
@@ -1,7 +1,12 @@
|
|||||||
name: Build moviepilot frontend
|
name: Build moviepilot frontend
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths:
|
||||||
|
- package.json
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
@@ -13,30 +18,30 @@ jobs:
|
|||||||
- name: Release version
|
- name: Release version
|
||||||
id: release_version
|
id: release_version
|
||||||
run: |
|
run: |
|
||||||
frontend_version=$(jq -r '.version' package.json)
|
frontend_version=$(jq -r '.version' package.json)
|
||||||
echo "frontend_version=v$frontend_version" >> $GITHUB_ENV
|
echo "frontend_version=v$frontend_version" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Setup node
|
- name: Setup node
|
||||||
uses: actions/setup-node@v3
|
uses: actions/setup-node@v3
|
||||||
with:
|
with:
|
||||||
node-version: '18'
|
node-version: '18'
|
||||||
cache: 'yarn'
|
cache: 'yarn'
|
||||||
|
|
||||||
- name: Build frontend
|
- name: Build frontend
|
||||||
id: build_frontend
|
id: build_frontend
|
||||||
run: |
|
run: |
|
||||||
yarn
|
yarn
|
||||||
yarn build
|
yarn build
|
||||||
zip -r dist.zip dist
|
zip -r dist.zip dist
|
||||||
|
|
||||||
- name: Generate Release
|
- name: Generate Release
|
||||||
uses: softprops/action-gh-release@v1
|
uses: softprops/action-gh-release@v1
|
||||||
with:
|
with:
|
||||||
tag_name: ${{ env.frontend_version }}
|
tag_name: ${{ env.frontend_version }}
|
||||||
name: ${{ env.frontend_version }}
|
name: ${{ env.frontend_version }}
|
||||||
draft: false
|
draft: false
|
||||||
prerelease: false
|
prerelease: false
|
||||||
files: |
|
files: |
|
||||||
dist.zip
|
dist.zip
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "moviepilot",
|
"name": "moviepilot",
|
||||||
"version": "1.0.2",
|
"version": "1.0.3",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite --host",
|
"dev": "vite --host",
|
||||||
|
|||||||
Reference in New Issue
Block a user