mirror of
https://gitlab.computer.surgery/matrix/grapevine.git
synced 2025-12-16 15:21:24 +01:00
don't try to set version extra outside flakes
The two attributes being accessed here don't exist when calling though flake-compat, so we need to handle that case by making the environment variable unset if neither attribute exists.
This commit is contained in:
parent
57c79b1999
commit
e11e27bc0c
1 changed files with 10 additions and 3 deletions
|
|
@ -57,9 +57,16 @@ let
|
|||
stdenv;
|
||||
});
|
||||
|
||||
buildPackageEnv = {
|
||||
GRAPEVINE_VERSION_EXTRA = inputs.self.shortRev or inputs.self.dirtyShortRev;
|
||||
} // buildDepsOnlyEnv;
|
||||
buildPackageEnv =
|
||||
let
|
||||
GRAPEVINE_VERSION_EXTRA = inputs.self.shortRev
|
||||
or inputs.self.dirtyShortRev
|
||||
or null;
|
||||
in
|
||||
(lib.optionalAttrs (GRAPEVINE_VERSION_EXTRA != null) {
|
||||
inherit GRAPEVINE_VERSION_EXTRA;
|
||||
})
|
||||
// buildDepsOnlyEnv;
|
||||
|
||||
commonAttrs = {
|
||||
# Reading from cargoManifest directly instead of using
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue