compiler/commands: make gitHash settable at compile-time. (#14654)
This is useful for building nightlies, since we will be building from a generated source archive and git metadata is lost there.
This commit is contained in:
parent
4e3edf5836
commit
d749c8cd87
1 changed files with 1 additions and 1 deletions
|
|
@ -98,7 +98,7 @@ proc writeVersionInfo(conf: ConfigRef; pass: TCmdLinePass) =
|
|||
CPU[conf.target.hostCPU].name, CompileDate]),
|
||||
{msgStdout})
|
||||
|
||||
const gitHash = gorge("git log -n 1 --format=%H").strip
|
||||
const gitHash {.strdefine.} = gorge("git log -n 1 --format=%H").strip
|
||||
when gitHash.len == 40:
|
||||
msgWriteln(conf, "git hash: " & gitHash, {msgStdout})
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue