mirror of
https://github.com/MetaCubeX/metacubexd.git
synced 2024-12-26 19:24:12 +08:00
ci: merge gh-pages and gh release into one job
This commit is contained in:
parent
54e5e1fc24
commit
37734942f7
49
.github/workflows/release.yml
vendored
49
.github/workflows/release.yml
vendored
@ -23,35 +23,6 @@ jobs:
|
|||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
release-type: node
|
release-type: node
|
||||||
|
|
||||||
gh-pages:
|
|
||||||
needs: release-please
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
if: ${{ needs.release-please.outputs.release_created }}
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v3
|
|
||||||
|
|
||||||
- uses: pnpm/action-setup@v2
|
|
||||||
with:
|
|
||||||
version: latest
|
|
||||||
|
|
||||||
- uses: actions/setup-node@v3
|
|
||||||
with:
|
|
||||||
cache: pnpm
|
|
||||||
node-version: latest
|
|
||||||
|
|
||||||
- name: build
|
|
||||||
env:
|
|
||||||
PUBLIC_PATH: '/metacubexd'
|
|
||||||
run: |
|
|
||||||
pnpm install
|
|
||||||
pnpm build
|
|
||||||
|
|
||||||
- name: Publish Github Pages
|
|
||||||
uses: peaceiris/actions-gh-pages@v3
|
|
||||||
with:
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
publish_dir: ./dist
|
|
||||||
|
|
||||||
release:
|
release:
|
||||||
needs: release-please
|
needs: release-please
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@ -68,10 +39,22 @@ jobs:
|
|||||||
cache: pnpm
|
cache: pnpm
|
||||||
node-version: latest
|
node-version: latest
|
||||||
|
|
||||||
- name: build
|
- name: install dependencies
|
||||||
run: |
|
run: pnpm install
|
||||||
pnpm install
|
|
||||||
pnpm build
|
- name: build for gh-pages
|
||||||
|
env:
|
||||||
|
PUBLIC_PATH: '/metacubexd'
|
||||||
|
run: pnpm build
|
||||||
|
|
||||||
|
- name: publish github pages
|
||||||
|
uses: peaceiris/actions-gh-pages@v3
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
publish_dir: ./dist
|
||||||
|
|
||||||
|
- name: build for release
|
||||||
|
run: pnpm build
|
||||||
|
|
||||||
- name: zip
|
- name: zip
|
||||||
run: |
|
run: |
|
||||||
|
Loading…
x
Reference in New Issue
Block a user