diff --git a/nix_update/__init__.py b/nix_update/__init__.py index 2ea5d54..d5d070e 100644 --- a/nix_update/__init__.py +++ b/nix_update/__init__.py @@ -114,6 +114,14 @@ def parse_args(args: list[str]) -> Options: help="Attribute of a subpackage that nix-update should try to update hashes for", default=None, ) + parser.add_argument( + "--option", + help="Nix option to set", + action="append", + nargs=2, + metavar=("name", "value"), + default=[], + ) a = parser.parse_args(args) return Options( @@ -140,6 +148,7 @@ def parse_args(args: list[str]) -> Options: generate_lockfile=a.generate_lockfile, lockfile_metadata_path=a.lockfile_metadata_path, extra_flags=(["--system", a.system] if a.system else []) + + [item for sublist in a.option for item in sublist] + ["--extra-experimental-features", "flakes nix-command"], )