64 Commits

Author SHA1 Message Date
Jess
7ef1c04d11 rclone: rename remote directory to fix failing tests
`/home/alice/files` is already used by the mount subtest.
2026-05-05 12:40:06 +02:00
Meow
b931102804 rclone: add serve options 2026-05-02 22:57:24 -05:00
Jess
79f8430e7d restic: unset systemd PrivateTmp option
This option works with the NixOS version of the module as host services
have different user namespace permissions to user services. Programs
like ssh get confused when certain config files aren't owned by root.
2026-04-28 08:33:38 -05:00
Austin Horstman
0a8d50edf2 docs/nix-flakes: clarify extraSpecialArgs usage
Explain when to use extraSpecialArgs versus _module.args in the flake setup guides, and keep the generated standalone fixture aligned with the updated template output.
2026-04-20 09:36:51 -05:00
Benedikt Rips
5a728e434d tests/integration: simplify pkgs.linkFarm usage 2026-04-13 22:02:40 -05:00
Benedikt Rips
a93d80bcec treewide: remove unused attrs patterns 2026-04-13 22:02:40 -05:00
Benedikt Rips
71402c5df3 treewide: mark unused lambda arguments 2026-04-13 22:02:40 -05:00
Robert Helgesson
5de7dbd151 restic: escape environment variables
This allows better handling of, e.g., file names with spaces.
2026-04-06 08:39:40 +02:00
nescias
e78a997d2e restic: allow setting password command
Includes asserting that either password file or password command
should be set.
2026-04-04 22:27:18 -05:00
Austin Horstman
11c89ba2e5 tests: stop pueued via alice user session in nixos-basics
Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
2026-03-03 14:24:37 -06:00
Adam C. Stephens
a71c7c601e home-environment: revert use nix profile add instead of install
This reverts commit e8d5fc77c2.
2026-03-02 23:32:28 -06:00
cethien
a5b92cc213 rclone: added sanitazion in systemd service name
- replaces $ and spaces
- escapes mount path
2026-02-26 21:02:03 -06:00
Bart Smykla
e8d5fc77c2 home-environment: use nix profile add instead of install
nix profile install was renamed to nix profile add in Nix 2.28.
The old name still works as a deprecated alias but produces a warning
on every home-manager switch:

  warning: 'install' is a deprecated alias for 'add'

Signed-off-by: Bart Smykla <bartek@smykla.com>
2026-02-22 11:22:48 +01:00
Yus314
de4cfffc98 kitty: add autoThemeFiles option
Add support for kitty's automatic theme switching based on OS
color scheme. This creates the required auto theme config files:
- light-theme.auto.conf
- dark-theme.auto.conf
- no-preference-theme.auto.conf

Closes: nix-community/home-manager#6869
2026-02-13 10:32:36 +01:00
Robert Helgesson
8434914a03 tests: fix integration tests 2026-01-21 13:14:01 +01:00
Jess
2954aa2944 rclone: add autoMount option 2026-01-18 23:02:16 -06:00
Jess
9e07a347f4 rclone: respect mounts enable option 2026-01-18 23:02:16 -06:00
Austin Horstman
fa6de26b4d treewide: nixf-diagnose cleanup
Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
2026-01-08 16:30:04 -05:00
Jess
a8b6296a1e tests/restic: fix timedatectl failure
Systemd
[added a check](6a12c90ca3)
which broke this test. So use `date` instead of `timedatectl`.
2025-12-04 22:39:18 -06:00
DDoSolitary
edbb012a21 dconf: support configuring specific user databases (#6301)
By default, dconf uses $XDG_CONFIG_HOME/dconf/user as the user database, but this can be changed by specifying user-db:<name> in a profile file and setting the DCONF_PROFILE environment variable to that profile. One may want to use different user databases for different DE/WMs to avoid collision.

Currently the module invokes dconf without touching DCONF_PROFILE, which means that 1) it is unable to configure multiple different user databases, and 2) the behavior of activation script will be affected by the DCONF_PROFILE environment variable when it is invoked, possibly leading to undesired results.

This PR adds a dconf.databases option, so that settings under dconf.databases.<name> will be written to $XDG_CONFIG_HOME/dconf/<name>. The old dconf.settings option is left as-is to avoid breaking compatibility.
2025-11-30 14:37:17 +01:00
Austin Horstman
af119feb17 Revert "tmpfiles: migrate to an RFC42-style option"
This reverts commit 090aa14e5d.

Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
2025-11-05 12:26:46 -06:00
Austin Horstman
06aeeed62f Revert "tmpfiles: add option to purge rules' targets on change"
This reverts commit b4350d54c2.

Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
2025-11-05 12:26:46 -06:00
bruce oberg
3c16ac3646 home manager: add test for option subcommand
- added a test to the standalone-basics unit:  the option subcommand queries the `home.username` value and ensures that something sane is returned.

details:

- the option subcommand was broken by upstream changes to the `nixos-option` command.
- hm had no tests for the option subcommand, so the problem was discovered by users.
- output from nixos-option probably starts with 'Value:\n  "alice"', but we're only looking for 'alice' because the output format is not guaranteed.
2025-11-03 09:12:22 -06:00
Benedikt Rips
b4350d54c2 tmpfiles: add option to purge rules' targets on change 2025-11-02 23:02:10 -06:00
Benedikt Rips
090aa14e5d tmpfiles: migrate to an RFC42-style option 2025-11-02 23:02:10 -06:00
Benedikt M. Rips
f2f1076c1f treewide: remove no-ops (#8061) 2025-10-26 15:43:53 -05:00
Robert Helgesson
12dfb0cff9 restic: fix integration test 2025-09-17 16:24:18 +02:00
Kylie McClain
e44549074a programs.rclone: fix injecting secret when value begins with "-" 2025-08-31 09:26:13 -05:00
Jess
3001400e9f rclone: move activation script to systemd service
Fixes #7577
This lets us better express activation order dependencies on secret
provisioners that run as systemd services
2025-08-21 16:02:50 -05:00
Jess
56b8749987 rclone: modularize subtests 2025-08-21 16:02:50 -05:00
Robert Helgesson
bd82507edd home-manager: re-enable gcroot handling for NixOS module
It was a bit too ambitious to also remove production of the gcroot, we
need it to keep track of the currently active Home Manager
configuration.

Fixes #7583
2025-07-31 08:25:36 +02:00
Austin Horstman
7a02711a61 tests: integration tests only run on linux
Using dependencies that require linux.

Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
2025-07-27 23:02:18 -05:00
Austin Horstman
b4752b0eda treewide: format with latest stable formatter
Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
2025-07-23 10:27:52 -05:00
Robert Helgesson
de448dcb57 home-manager: avoid profile management during activation
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 --specialisation NAME`, which switches to the
  named specialisation. While it was previously possible to accomplish
  this by manually running the specialisation activate script, 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
2025-07-22 11:00:18 +02:00
Robert Helgesson
bf893ad4cb tests: re-add module argument
These were removed as part of dead code removal, but they are actually
needed in the integration tests for comparing with the configuration
generated by the installation.
2025-07-13 12:27:35 +02:00
awwpotato
76d0c31fce formatter: add deadnix (#7331) 2025-06-28 16:28:39 -05:00
Robert Helgesson
eee140958a home-manager: fix integration tests 2025-06-09 16:08:02 +02:00
Jess
dbc90cc3ae rclone: declarative mounts (#7060) 2025-05-15 13:33:51 -05:00
awwpotato
5da6eafceb treewide: remove unused code (#6985) 2025-05-07 10:03:21 -05:00
Jess
2eabb26d08 restic: allow the convenience script to source environmentFile (#6947) 2025-05-02 08:23:57 -05:00
Jess
5f217e5a31 restic: change service type from simple to oneshot
Fixes #6930
2025-04-30 14:19:59 -05:00
Jess
7f301a4d96 restic: fix certain integration tests 2025-04-30 14:19:59 -05:00
Jess
f98314bb06 restic: init module (#6729) 2025-04-19 22:53:06 -07:00
Austin Horstman
cba2f9ce95 treewide: reformat nixfmt-rfc-style
Reformat repository using new nixfmt-rfc-style.
2025-04-08 08:50:05 -07:00
Jess
7853236fae rclone: ensure remotes have a type field 2025-03-22 21:52:23 -05:00
Jess
7a08b8c898 rclone: correctly escape whitespace in secrets 2025-03-22 21:52:23 -05:00
Jess
eb5d59dac9 rclone: add module
Rclone is a command-line program to manage files on cloud storage, it
also featrues support for FUSE mounts.

"Users call rclone *"The Swiss army knife of cloud storage"* and
*"Technology indistinguishable from magic"*" - https://rclone.org/

This module manages the configuration of rclone remotes.
2025-03-19 13:49:44 -05:00
Austin Horstman
439a125afe tests: remove with lib (#6511) 2025-02-21 23:20:07 -06:00
Robert Helgesson
1e68dc759b home-manager: move profile management
This commit separates profile management (setting profile and creating
GC root) from file management (removing and adding managed files
within the user's home directory).

This is a step towards deprecating profile management within the
activation script, instead relying on the caller of the activation
script managing the profile.
2025-01-03 11:22:59 +01:00
Robert Helgesson
9a9fef316a systemd: use sd-switch by default
Also remove the legacy Ruby alternative.

Fixes #5452
2025-01-01 16:31:32 +01:00