Skip to content

Commit

Permalink
Automatically update version when pushing a tag
Browse files Browse the repository at this point in the history
  • Loading branch information
Ircama committed Nov 16, 2024
1 parent 0f163a6 commit 637667b
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,19 @@ jobs:
- name: Git Checkout
uses: actions/checkout@v4

- name: Update VERSION in python file ui.py
run: (Get-Content ui.py) -replace '^VERSION = ".*"$', 'VERSION = "${{ github.ref_name }}"' | Set-Content ui.py

- name: Commit version update
run: |
git config --local user.name "github-actions[bot]"
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git commit -m "Update VERSION to ${{ github.ref_name }}"
- name: Push changes
run: |
git push
- name: Install Python
uses: actions/setup-python@v5
with:
Expand All @@ -27,9 +40,7 @@ jobs:
pip install -r requirements.txt
- name: Run PyInstaller to create epson_print_conf.exe
run: >
python -m PyInstaller epson_print_conf.spec -- --default
--version ${{ github.ref_name }}
run: python -m PyInstaller epson_print_conf.spec -- --default

- name: Zip the epson_print_conf.exe asset to epson_print_conf.zip
run: |
Expand Down

0 comments on commit 637667b

Please sign in to comment.