chore: inline build version within PanicReporter
This commit is contained in:
parent
926858aeec
commit
b3816bc2dc
@ -79,11 +79,7 @@ func writeAppVersion(file string) {
|
|||||||
}
|
}
|
||||||
defer f.Close() //nolint:errcheck
|
defer f.Close() //nolint:errcheck
|
||||||
|
|
||||||
ignoreCommitBefore := os.Getenv("LOTUS_VERSION_IGNORE_COMMIT")
|
versionString := []byte(BuildVersion + buildType() + CurrentCommit + "\n")
|
||||||
os.Setenv("LOTUS_VERSION_IGNORE_COMMIT", "") //nolint:errcheck
|
|
||||||
defer os.Setenv("LOTUS_VERSION_IGNORE_COMMIT", ignoreCommitBefore) //nolint:errcheck
|
|
||||||
|
|
||||||
versionString := []byte(UserVersion() + "\n")
|
|
||||||
if _, err := f.Write(versionString); err != nil {
|
if _, err := f.Write(versionString); err != nil {
|
||||||
panicLog.Error(err.Error())
|
panicLog.Error(err.Error())
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user