Loading pkgs/by-name/ni/nixos-rebuild-ng/src/nixos_rebuild/constants.py +6 −4 Original line number Diff line number Diff line from typing import Final # Build-time flags # Use strings to avoid breaking standalone (e.g.: `python -m nixos_rebuild`) # usage EXECUTABLE = "@executable@" EXECUTABLE: Final[str] = "@executable@" # Use either `== "true"` if the default (e.g.: `python -m nixos_rebuild`) is # `False` or `!= "false"` if the default is `True` WITH_NIX_2_18 = "@withNix218@" != "false" # type: ignore WITH_REEXEC = "@withReexec@" == "true" # type: ignore WITH_SHELL_FILES = "@withShellFiles@" == "true" # type: ignore WITH_NIX_2_18: Final[bool] = "@withNix218@" != "false" WITH_REEXEC: Final[bool] = "@withReexec@" == "true" WITH_SHELL_FILES: Final[bool] = "@withShellFiles@" == "true" Loading
pkgs/by-name/ni/nixos-rebuild-ng/src/nixos_rebuild/constants.py +6 −4 Original line number Diff line number Diff line from typing import Final # Build-time flags # Use strings to avoid breaking standalone (e.g.: `python -m nixos_rebuild`) # usage EXECUTABLE = "@executable@" EXECUTABLE: Final[str] = "@executable@" # Use either `== "true"` if the default (e.g.: `python -m nixos_rebuild`) is # `False` or `!= "false"` if the default is `True` WITH_NIX_2_18 = "@withNix218@" != "false" # type: ignore WITH_REEXEC = "@withReexec@" == "true" # type: ignore WITH_SHELL_FILES = "@withShellFiles@" == "true" # type: ignore WITH_NIX_2_18: Final[bool] = "@withNix218@" != "false" WITH_REEXEC: Final[bool] = "@withReexec@" == "true" WITH_SHELL_FILES: Final[bool] = "@withShellFiles@" == "true"