update ci
This commit is contained in:
parent
5c56f2146f
commit
e988fc7ae9
6
.github/workflows/auto-build.yml
vendored
6
.github/workflows/auto-build.yml
vendored
@ -39,13 +39,13 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout codes
|
- name: Checkout codes
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
- name: Checkout LFS file list
|
- name: Checkout LFS file list
|
||||||
run: git lfs ls-files --long | cut -d ' ' -f1 | sort > .lfs-assets-id
|
run: git lfs ls-files --long | cut -d ' ' -f1 | sort > .lfs-assets-id
|
||||||
- name: LFS Cache
|
- name: LFS Cache
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: .git/lfs/objects
|
path: .git/lfs/objects
|
||||||
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}
|
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}
|
||||||
@ -60,7 +60,7 @@ jobs:
|
|||||||
- run: npm install
|
- run: npm install
|
||||||
- run: npm test
|
- run: npm test
|
||||||
- run: npm run build
|
- run: npm run build
|
||||||
- uses: actions/upload-artifact@v2
|
- uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: my-dist
|
name: my-dist
|
||||||
path: |
|
path: |
|
||||||
|
|||||||
52
.github/workflows/release.yml
vendored
52
.github/workflows/release.yml
vendored
@ -42,13 +42,13 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout codes
|
- name: Checkout codes
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
- name: Checkout LFS file list
|
- name: Checkout LFS file list
|
||||||
run: git lfs ls-files --long | cut -d ' ' -f1 | sort > .lfs-assets-id
|
run: git lfs ls-files --long | cut -d ' ' -f1 | sort > .lfs-assets-id
|
||||||
- name: LFS Cache
|
- name: LFS Cache
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: .git/lfs/objects
|
path: .git/lfs/objects
|
||||||
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}
|
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}
|
||||||
@ -63,44 +63,14 @@ jobs:
|
|||||||
- run: npm install
|
- run: npm install
|
||||||
- run: npm test
|
- run: npm test
|
||||||
- run: npm run build
|
- run: npm run build
|
||||||
- name: Create Release
|
- name: Create Release And Upload
|
||||||
id: create_release
|
uses: softprops/action-gh-release@v2
|
||||||
uses: actions/create-release@v1
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
VERSION: ${{ github.ref }}
|
|
||||||
with:
|
with:
|
||||||
tag_name: ${{ github.ref }}
|
files: |
|
||||||
release_name: ${{ github.ref }}
|
main.js
|
||||||
|
manifest.json
|
||||||
|
style.css
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
draft: false
|
draft: false
|
||||||
prerelease: true
|
prerelease: false
|
||||||
- name: Upload main.js
|
make_latest: true
|
||||||
id: upload-main
|
|
||||||
uses: actions/upload-release-asset@v1
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
||||||
asset_path: ./main.js
|
|
||||||
asset_name: main.js
|
|
||||||
asset_content_type: text/javascript
|
|
||||||
- name: Upload manifest.json
|
|
||||||
id: upload-manifest
|
|
||||||
uses: actions/upload-release-asset@v1
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
||||||
asset_path: ./manifest.json
|
|
||||||
asset_name: manifest.json
|
|
||||||
asset_content_type: application/json
|
|
||||||
- name: Upload styles.css
|
|
||||||
id: upload-styles
|
|
||||||
uses: actions/upload-release-asset@v1
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
||||||
asset_path: ./styles.css
|
|
||||||
asset_name: styles.css
|
|
||||||
asset_content_type: text/css
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user