Skip to content

Commit

Permalink
Update build.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
DeepSeaTeam authored Apr 30, 2024
1 parent d15ef08 commit 5935c83
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,20 @@ jobs:
build:
runs-on: windows-latest

env:
VERSION: '1.0.0'

steps:
- uses: actions/checkout@v4
- name: Set up Python 3.12
uses: actions/setup-python@v3
with:
python-version: '3.12'

- name: Install 7zip
run: |
choco install 7zip -y
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand All @@ -30,16 +37,16 @@ jobs:
mkdir DamaiHelper_Build
cp dist/main.exe DamaiHelper_Build/DamaiHelper.exe
cp config.json DamaiHelper_Build/config.json
zip -r DamaiHelper_V${{ github.run_number }}_Windows.zip DamaiHelper_Build
7z a DamaiHelper_V${{ env.VERSION }}_Windows.zip DamaiHelper_Build
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.ACTIONS_TOKEN }}
with:
tag_name: v${{ github.run_number }}
release_name: DamaiHelper v${{ github.run_number }} Release
tag_name: v${{ env.VERSION }}
release_name: DamaiHelper v${{ env.VERSION }} Release
body: |
Description of the release.
draft: false
Expand All @@ -52,6 +59,6 @@ jobs:
GITHUB_TOKEN: ${{ secrets.ACTIONS_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: DamaiHelper_V${{ github.run_number }}_Windows.zip
asset_name: DamaiHelper_V${{ github.run_number }}_Windows.zip
asset_path: DamaiHelper_V${{ env.VERSION }}_Windows.zip
asset_name: DamaiHelper_V${{ env.VERSION }}_Windows.zip
asset_content_type: application/zip

0 comments on commit 5935c83

Please sign in to comment.