Skip to content

Commit

Permalink
Try git describe --tags --always for shallow clones in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
manics committed Jul 25, 2023
1 parent 655f484 commit 2df194b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion git-version.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const path = require('path');
const { execSync } = require('child_process');

const main = () => {
const gitDescribe = execSync('git describe --tags').toString().trim();
const gitDescribe = execSync('git describe --tags --always').toString().trim();

const filePath = path.resolve('src', 'version.json');
const fileContents = JSON.stringify({ version: gitDescribe }, null, 2);
Expand Down

0 comments on commit 2df194b

Please sign in to comment.