This commit deprecates profile management from the activation script.
The profile management is instead the responsibility of the driving
software, for example, the `home-manager` tool in the case of
standalone installs.
The legacy behavior is still available for backwards compatibility but
may be removed in the future.
The new behavior resolves (or moves us closer to resolving) a number
of long standing open issues:
- `home-manager switch --rollback`, which performs a rollback to the
previous Home Manager generation before activating. While it was
previously possible to accomplish this by activating an old
generation, it did always create a new profile generation.
This option has been implemented as part of this commit.
- `home-manager switch --test`, which activates the configuration but
does not create a new profile generation.
This option has _not_ been implemented here since it relies on the
current configuration being activated on login, which we do not
currently do.
- When using the "Home Manager as a NixOS module" installation method
we previously created an odd `home-manager` per-user "shadow
profile" for the user. This is no longer necessary.
This has been implemented as part of this commit.
Fixes#3450
* nix: add options 'nixPath' and 'keepOldNixPath'
By default, the system value for $NIX_PATH is kept as a fallback.
To completely override the system value for $NIX_PATH:
nix.keepOldNixPath = false;
* nix: add more tests
* nix: add a declarative alternative to Nix channels
This adds a new option, 'nix.channels'. It's the Nix channels equivalent
of the 'nix.registry' option, and compatible with pre-Flake Nix tooling
including nix-env and nix-shell. Like 'nix.registry', this option is
useful for pinning Nix channels.
Channels defined in the new option can coexist with channels introduced
through the nix-channel command. If the same channel exists in both, the
one from Home Manager will be prioritized.
* nix: add news entry
* nix: make channels respect use-xdg-base-directories
* nix: remove 'with lib;'
---------
Co-authored-by: Michael Hoang <enzime@users.noreply.github.com>
Some prefer to handle modules-* imperatively for more flexibility, e.g.,
via waybar "includes" (https://github.com/Alexays/Waybar/wiki/Configuration).
Current HM defaults modules-* to `[]` instead of null for most other
settings, so they get written to ~/.config/waybar/config even though
no explicit configuration has been made.
And they take precedence over the imperative ones because of how
waybar's includes work:
====
Paths to additional configuration files.
Each file can contain a single object with any of the bar configuration options. In case of duplicate options, the first defined value takes precedence, i.e. including file -> first included file -> etc. Nested includes are permitted, but make sure to avoid circular imports.
For a multi-bar config, the include directive affects only current bar configuration object.
====
To avoid this kind of message:
swayidle[181123]: - [Line 1054] Unable to connect to the compositor. If your compositor is running, check or set the WAYLAND_DISPLAY environment variable.
The 24.05 update for KDE Connect moved the kdeconnectd binary from
`/libexec` to `/bin`, so this fix will check the version of the
package used and set the path accordingly.
`splitString "" "some string"` would throw exception `error: invalid
regular expression` on Darwin (or accurately, on Nix built against
libc++). Refer to https://github.com/NixOS/nix/issues/7208 for
details.
Before Nix handles that issue correctly, we should refrain from using
`splitString ""`, and luckliy `lib.stringAsChars` can do the same thing.
Using the option
wayland.windowManager.hyprland.systemd.enableXdgAutostart
users can now choose to start applications present in
`$XDG_CONFIG_HOME/autostart` when starting their sway session.
See 0144ac418e and
https://github.com/nix-community/home-manager/pull/3747
We currently have no way of specifying the sender's name inside the
From field, making a patch sent through `git send-email` appear as
coming from "xxx@domain.com".
In this commit we make this field follow the standard
realName <email>
format.