ci: improve commit checking and update release version script (#4471)

- Increase `fetch-depth` to 50 for more accurate commit history in CI
- Update `release-version.mjs` to use `bash` explicitly for improved compatibility
  - Also avoid errors when invoking the script

Signed-off-by: Dragon1573 <49941141+Dragon1573@users.noreply.github.com>
This commit is contained in:
❤是纱雾酱哟~
2025-08-21 21:16:15 +08:00
committed by GitHub
Unverified
parent 9397ac0174
commit a2544d237e
2 changed files with 2 additions and 2 deletions

View File

@@ -55,7 +55,7 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 2
fetch-depth: 50
- name: Check if version changed or src changed
id: check

View File

@@ -53,7 +53,7 @@ function getGitShortCommit() {
*/
function getLatestTauriCommit() {
try {
const fullHash = execSync("./scripts-workflow/get_latest_tauri_commit.bash")
const fullHash = execSync("bash ./scripts-workflow/get_latest_tauri_commit.bash")
.toString()
.trim();
return execSync(`git rev-parse --short ${fullHash}`).toString().trim();