{
  writeShellApplication,
  coreutils,
  gnugrep,
  gnused,
  home-manager,
  hostname,
  nix,
  nixos-rebuild-ng,
  ...
}:

let
  name = "rebuild";
  text = builtins.readFile ./${name}.sh;
in
writeShellApplication {
  inherit name text;
  meta.mainProgram = name;

  runtimeInputs = [
    coreutils
    gnugrep
    gnused
    home-manager
    hostname
    nix
    nixos-rebuild-ng
  ];
}
