File tree Expand file tree Collapse file tree 1 file changed +10
-5
lines changed Expand file tree Collapse file tree 1 file changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -58,11 +58,16 @@ function get_bb_version()
58
58
gitsha = string (LibGit2. GitHash (LibGit2. GitCommit (repo, " HEAD" )))
59
59
return VersionNumber (" $(version) -git-$(gitsha[1 : 10 ]) " )
60
60
catch
61
- # Settle for the treehash otherwise
62
- env = Pkg. Types. Context (). env
63
- bb_uuid = Pkg. Types. UUID (" 12aac903-9f7c-5d81-afc2-d9565ea332ae" )
64
- treehash = bytes2hex (env. manifest[bb_uuid]. tree_hash. bytes)
65
- return VersionNumber (" $(version) -tree-$(treehash[1 : 10 ]) " )
61
+ try
62
+ # Settle for the treehash otherwise
63
+ env = Pkg. Types. Context (). env
64
+ bb_uuid = Pkg. Types. UUID (" 12aac903-9f7c-5d81-afc2-d9565ea332ae" )
65
+ treehash = bytes2hex (env. manifest[bb_uuid]. tree_hash. bytes)
66
+ return VersionNumber (" $(version) -tree-$(treehash[1 : 10 ]) " )
67
+ catch
68
+ # Something went so wrong, we can't get any of that.
69
+ return VersionNumber (version)
70
+ end
66
71
end
67
72
end
68
73
You can’t perform that action at this time.
0 commit comments