Skip to content

Commit

Permalink
Merge pull request #1023 from cachix/backward-compatible-tmpdir
Browse files Browse the repository at this point in the history
backward compatible devenv.tmpdir
  • Loading branch information
domenkozar authored Mar 21, 2024
2 parents 47363a7 + 60df0f3 commit e6482de
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
8 changes: 5 additions & 3 deletions devenv/src/flake.tmpl.nix
Original file line number Diff line number Diff line change
Expand Up @@ -63,12 +63,14 @@
devenv.cliVersion = version;
devenv.root = devenv_root;
devenv.dotfile = pkgs.lib.mkForce (devenv_root + "/" + devenv_dotfile_string);
devenv.tmpdir = tmpdir;
}
(if container_name != null then {
(pkgs.lib.optionalAttrs (inputs.devenv.isTmpDir or false) {
devenv.tmpdir = tmpdir;
})
(pkgs.lib.optionalAttrs (container_name != null) {
container.isBuilding = pkgs.lib.mkForce true;
containers.${container_name}.isBuilding = true;
} else { })
})
] ++ (map importModule (devenv.imports or [ ])) ++ [
./devenv.nix
(devenv.devenv or { })
Expand Down
1 change: 1 addition & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@
});

modules = ./src/modules;
hasTmpDir = true;

templates =
let
Expand Down
1 change: 1 addition & 0 deletions src/modules/flake.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
outputs = { ... }: {
modules = ./.;
hasTmpDir = true;
};
}

0 comments on commit e6482de

Please sign in to comment.