Skip to content
This repository was archived by the owner on Mar 8, 2025. It is now read-only.

Commit

Permalink
自动更新插件版本号
Browse files Browse the repository at this point in the history
  • Loading branch information
ACaiCat authored Oct 3, 2024
1 parent e070777 commit 321effc
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,20 @@ jobs:
with:
dotnet-version: 8.0.x

- name: Update version in build.txt
run: |
$date = Get-Date -Format "yyyy.MM.dd"
(Get-Content CaiBotMod/build.txt) -replace 'version = \d+\.\d+\.\d+', "version = $date" | Set-Content CaiBotMod/build.txt
- name: Commit changes
run: |
git config --global user.name 'github-actions'
git config --global user.email 'github-actions@github.com'
git add CaiBotMod/build.txt
git commit -m "自动更新版本号 v$date [skip ci]"
git push
continue-on-error: true

- name: Download TMODL
run: |
Invoke-WebRequest -Uri "https://github.com/tModLoader/tModLoader/releases/latest/download/tModLoader.zip" -OutFile "tModLoader.zip"
Expand Down

0 comments on commit 321effc

Please sign in to comment.