1 parent ea744e9 commit 5500564Copy full SHA for 5500564
1 file changed
.github/workflows/deploy.yml
@@ -40,7 +40,7 @@ jobs:
40
41
- name: 更新版本号
42
run: |
43
- ver=$(git describe --tags --always --match "v*" 2>/dev/null || echo "v0.0.1")
+ ver=$(git describe --tags --long --match "v*" 2>/dev/null || echo "v0.0.1-0-g$(git rev-parse --short HEAD)")
44
ver=${ver#v}
45
echo "Setting version to ${ver}"
46
npm pkg set version=${ver}
0 commit comments