Skip to content

Determine if you need to reboot ️♻️ your NixOS machine ️❄️

License

Notifications You must be signed in to change notification settings

wimpysworld/nixos-needsreboot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

nixos-needsreboot

FlakeHub

Checks if you should reboot your NixOS ️❄️ machine in case an upgrade delivered new toys 🎁

This project is forked from https://codeberg.org/Mynacol/nixos-needsreboot, which was forked from https://github.com/thefossguy/nixos-needsreboot. My version only makes aesthetic changes to the output ✨ to suit my taste.

Usage as a flake

Add nixos-needsreboot to your flake.nix:

{
  inputs.nixos-needsreboot.url = "https://flakehub.com/f/wimpysworld/nixos-needsreboot/*.tar.gz";

  outputs = { self, nixos-needsreboot }: {
    # Use in your outputs
  };
}

Usage

Check if the currently active system needs a reboot

nixos-needsreboot

Check a different system if it would require a reboot

nixos-needsreboot [/path/to/different-system]

Test during NixOS system activation

  system.activationScripts = {
    nixos-needsreboot = {
      supportsDryActivation = true;
      text = "${lib.getExe nixos-needsreboot.packages.${pkgs.system}.default} \"$systemConfig\" || true";
    };
  };

About

Determine if you need to reboot ️♻️ your NixOS machine ️❄️

Topics

Resources

License

Stars

Watchers

Forks

Sponsor this project