mirror of
https://github.com/defnull/fediwall.git
synced 2024-11-25 09:03:16 +01:00
Fix version string when building with github actions
This commit is contained in:
parent
a766bb1ba8
commit
c0c770e86c
2
.github/workflows/deploy-pages.yml
vendored
2
.github/workflows/deploy-pages.yml
vendored
@ -15,6 +15,8 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
fetch-depth: 0 # Needed for tags
|
||||||
- uses: actions/setup-node@v3
|
- uses: actions/setup-node@v3
|
||||||
with:
|
with:
|
||||||
node-version: 18
|
node-version: 18
|
||||||
|
@ -9,9 +9,11 @@ var version;
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
var gitInfo = gitDescribeSync();
|
var gitInfo = gitDescribeSync();
|
||||||
version = `${gitInfo.tag}`;
|
if(gitInfo.tag) {
|
||||||
if (gitInfo.distance)
|
version = `${gitInfo.tag}`;
|
||||||
version += `-${gitInfo.distance}+${gitInfo.hash}`
|
if (gitInfo.distance)
|
||||||
|
version += `-${gitInfo.distance}+${gitInfo.hash}`
|
||||||
|
}
|
||||||
} catch { }
|
} catch { }
|
||||||
|
|
||||||
// https://vitejs.dev/config/
|
// https://vitejs.dev/config/
|
||||||
|
Loading…
Reference in New Issue
Block a user