all 29 comments

sorted by: hot top controversial new old
[–] 39 points 1 year ago (22 children)

Is this some declarative joke I am too imperative to understand?

  • source
  • hideshow 22 child comments
  • [–] 17 points 1 year ago (21 children)

    Info:

    nixos-rebuild switch = build the new system configuration (from /etc/nixos/configuration.nix or flakes) and activate it immediately without reboot.

    • It builds the new system in /nix/store.
    • Updates the GRUB/systemd-boot entries.
    • Switches to the new configuration right away (systemd units, services, kernel params if possible, etc.).
    • Leaves the old generations available for rollback (nixos-rebuild switch --rollback).

    So: "switch" means build + activate now

  • source
  • parent
  • hideshow 21 child comments
  • [–] 8 points 1 year ago (20 children)

    I never use nixos, but I just got intrusive thought to make that command get invoked automatically every time the config file is modified.

  • source
  • parent
  • hideshow 20 child comments
  • [–] 15 points 1 year ago (8 children)

    My most intrusive Linux thought is to symlink vi to emacs (or vice versa).

  • source
  • parent
  • hideshow 8 child comments
  • [–] 13 points 1 year ago (4 children)

    I will find you, and I will break your fingers.

  • source
  • parent
  • hideshow 4 child comments
  • [–] 6 points 1 year ago (2 children)

    You cannot [break my fingers] in any way that [Emacs hasn't already hardened].

  • source
  • parent
  • hideshow 2 child comments
  • [–] 2 points 1 year ago (1 child)

    or nano to $EDITOR, if you like copy-pasting commands from tutorials.

  • source
  • parent
  • hideshow 1 child comment
  • [–] 3 points 1 year ago

    Well, to be fair, that one is easier to undo (and, depending on the command you pasted, might take care of itself when you start a new session).

    But yeah ... Running visudo and getting a nano interface should be illegal IMHO.

  • source
  • parent
  • [–] 3 points 1 year ago (9 children)

    I'm only two days into Nixos, but I don't think that would be a problem. I am at 14 generations of my system already, and it asks me every boot which generation I want to start. It's trivial to scroll down and pick an earlier (working) version.

    One thing that might be nice would be if that menu indicated how many times each generation had been booted and used for more than 10 min, so I could tell which ones were "real" versions and which were transitional.

  • source
  • parent
  • hideshow 9 child comments
  • [–] 5 points 1 year ago* (last edited 1 year ago) (3 children)

    It helps to run the garbage collector and clean out the Nix store. Once you get a stable version that works, clear your nix store.

    See this built in helper script

    If you're new you might have a bunch of stuff in the store from trying out things. You can also delete objects older than a certain period, which is nice.

  • source
  • parent
  • hideshow 3 child comments
  • [–] 2 points 1 year ago

    I'm not even to the point of trying out alternative software, I'm just trying to get the right configs so I can use the dang thing!

    I tried to get screenshots working, and now the system is completely unresponsive, mouse never moves etc. Ok, back to previous version. Between here and working, I'm sure I'll go through dozens more versions! I'm trying to only make small changes every time.

  • source
  • parent
  • [–] 2 points 1 year ago (1 child)

    I saw the garbage collection for old stuff, but I'm still setting things up for the first time especially since I'm trying Wayland and Hyprland for the first time. Every other generation works, probably! I'm really enjoying the process, except that I need this computer and the downtime is a problem.

    Do you know a way to delete either all generations except the current, or maybe the current ly booted one and the one previous to it? (Not the latest one explicitly as I keep breaking things)

  • source
  • parent
  • hideshow 1 child comment
  • [–] 2 points 1 year ago (4 children)

    I don’t have the command at hand but you can name versions.

  • source
  • parent
  • hideshow 4 child comments
  • [–] 5 points 1 year ago (2 children)

    Ooh that's handy.

    NIXOS_LABEL="changed-some-settings" nixos-rebuild switch

  • source
  • parent
  • hideshow 2 child comments
  • [–] 6 points 1 year ago

    nh os switch --update --ask

  • source
  • [–] 4 points 1 year ago (3 children)

    Sudo nixos-rebuild switch —flake .#geoff

  • source
  • hideshow 3 child comments
  • [–] 3 points 1 year ago