Skip to content

Commit

Permalink
add detached CLI option (#87)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamcstephens authored Nov 8, 2024
1 parent 7241e6b commit b590e39
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion nix/process-compose/cli.nix
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@ in
default = { };
type = types.submodule {
options = {
detached = mkOption {
type = types.bool;
default = false;
description = "Pass --detached to process-compose";
};
log-file = mkOption {
type = types.nullOr types.str;
default = null;
Expand Down Expand Up @@ -80,7 +85,8 @@ in
readOnly = true;
description = "The final CLI arguments we will pass to process-compose binary.";
default = let o = config.cli.options; in lib.escapeShellArgs (
(lib.optionals (o.log-file != null) [ "--log-file" o.log-file ])
(lib.optionals o.detached [ "--detached" ])
++ (lib.optionals (o.log-file != null) [ "--log-file" o.log-file ])
++ (lib.optionals o.no-server [ "--no-server" ])
++ (lib.optionals o.ordered-shutdown [ "--ordered-shutdown" ])
++ (lib.optionals (o.port != null) [ "--port" "${builtins.toString o.port}" ])
Expand Down

0 comments on commit b590e39

Please sign in to comment.