Skip to content

Commit

Permalink
build: update build script
Browse files Browse the repository at this point in the history
  • Loading branch information
cxfksword committed Dec 2, 2023
1 parent 17a2d09 commit e3a559d
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/beta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ jobs:
run: |
VERSION=$(echo "${GITHUB_REF#refs/*/}" | sed s/^v//)
VERSION="$VERSION.0"
echo ::set-output name=VERSION::${VERSION}
echo ::set-output name=APP_NAME::$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')
echo "VERSION=${VERSION}" >> $GITHUB_OUTPUT
echo "APP_NAME=$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')" >> $GITHUB_OUTPUT
- name: Build
run: |
dotnet restore ${{ env.project }} --no-cache
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ jobs:
run: |
VERSION=$(echo "${GITHUB_REF#refs/*/}" | sed s/^v//)
VERSION="$VERSION.0"
echo ::set-output name=VERSION::${VERSION}
echo ::set-output name=APP_NAME::$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')
echo "VERSION=${VERSION}" >> $GITHUB_OUTPUT
echo "APP_NAME=$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')" >> $GITHUB_OUTPUT
- name: Build
run: |
dotnet restore ${{ env.project }} --no-cache
Expand All @@ -55,6 +55,7 @@ jobs:
destination_dir: ${{ env.artifact }}
publish_branch: master
publish_dir: ./artifacts
keep_files: true
- name: Publish release
uses: svenstaro/upload-release-action@v2
with:
Expand Down
2 changes: 1 addition & 1 deletion scripts/generate_manifest.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def main():
raise

# 追加新版本/覆盖旧版本
manifest[0]['versions'] = list(filter(lambda x: x['version'] == version, manifest[0]['versions']))
manifest[0]['versions'] = list(filter(lambda x: x['version'] != f"{version}.0", manifest[0]['versions']))
manifest[0]['versions'].insert(0, generate_version(filepath, version, changelog))

with open('manifest.json', 'w') as f:
Expand Down

0 comments on commit e3a559d

Please sign in to comment.