diff options
author | lassulus <lassulus@lassul.us> | 2019-04-13 15:39:40 +0200 |
---|---|---|
committer | lassulus <lassulus@lassul.us> | 2019-04-13 15:39:40 +0200 |
commit | 7f9b2c6f45ce0ca09c0fe8ba07fab16bf4428f38 (patch) | |
tree | 10a562fb47a0fea88c71d585338f3b8e4cd8fb0a | |
parent | 3ccac0c30e77501d40c2fc29122e59fe87bd60fa (diff) |
ci: create gcroot only if result exists
-rw-r--r-- | krebs/3modules/ci.nix | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/krebs/3modules/ci.nix b/krebs/3modules/ci.nix index a47dbe611..244de1a0d 100644 --- a/krebs/3modules/ci.nix +++ b/krebs/3modules/ci.nix @@ -108,10 +108,12 @@ let name=str(new_step), command=[ "${pkgs.writeDash "build-stepper.sh" '' - set -efu + set -xefu profile=${shell.escape profileRoot}/$build_name result=$("$build_script") - ${pkgs.nix}/bin/nix-env -p "$profile" --set "$result" + if [ -n "$result" ]; then + ${pkgs.nix}/bin/nix-env -p "$profile" --set "$result" + fi ''}" ], env={ |