-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
systemd: fix creation of user service unit files #2867
systemd: fix creation of user service unit files #2867
Conversation
ec7e0fb
to
bdb34bd
Compare
This seems to be caused by NixOS/nixpkgs#162246 , but I'm not a big fan of the |
Ok, I tested several options, and it seems the issue is caused because of double-applying diff --git a/modules/systemd.nix b/modules/systemd.nix
index cd5b30ed..0be586d7 100644
--- a/modules/systemd.nix
+++ b/modules/systemd.nix
@@ -41,7 +41,7 @@ let
source = pkgs.writeTextFile {
name = pathSafeName;
text = toSystemdIni serviceCfg;
- destination = lib.escapeShellArg "/${filename}";
+ destination = "/${filename}";
} + "/${filename}";
wantedBy = target: { |
It seems like this PR does not have the second, simpler fix, is this a mistake? |
bdb34bd
to
8ffe592
Compare
Sorry @andresilva, I took the liberty to force push the "simpler" fix on your branch. |
It contains a fix from nix-community/home-manager#2867 (comment). Flake lock file updates: • Updated input 'home-manager': 'github:nix-community/home-manager/07b941f0c45ac4af6732d96f4cb6142824eee3df' (2022-04-05) → 'github:wentasah/home-manager/7bf9f0cd90169f93fa581dcd8db971eb7aa60ce7' (2022-04-06)
@berbiche no worries, made sense to get this merged asap and simpler is better :) |
* systemd: fix creation of user service unit files * helix: fix failing test due to file output format change Co-authored-by: Nicolas Berbiche <nicolas@normie.dev>
Is there any new release in |
* systemd: fix creation of user service unit files * helix: fix failing test due to file output format change Co-authored-by: Nicolas Berbiche <nicolas@normie.dev>
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
This fixes an issue with user service unit files [1]. The relevant news / changelog entries are here [2]. [1] nix-community/home-manager#2867 [2] https://github.com/nix-community/home-manager/blob/620ed197f3624dafa5f42e61d5c043f39b8df366/modules/misc/news.nix#L2332
I have opened a nixpkgs PR: NixOS/nixpkgs#169084 |
This fixes an issue with user service unit files [1]. The relevant news / changelog entries are here [2]. [1] nix-community/home-manager#2867 [2] https://github.com/nix-community/home-manager/blob/620ed197f3624dafa5f42e61d5c043f39b8df366/modules/misc/news.nix#L2332
Could this be backported to EDIT: I found a better solution than to depend on a specific |
* systemd: fix creation of user service unit files * helix: fix failing test due to file output format change Co-authored-by: Nicolas Berbiche <nicolas@normie.dev>
* systemd: fix creation of user service unit files * helix: fix failing test due to file output format change Co-authored-by: Nicolas Berbiche <nicolas@normie.dev>
Description
Fix #2846, diff provided by @yu-re-ka.
Checklist
Change is backwards compatible.
Code formatted with
./format
.Code tested through
nix-shell --pure tests -A run.all
.Test cases updated/added. See example.
Commit messages are formatted like
See CONTRIBUTING for more information and recent commit messages for examples.
If this PR adds a new module
Added myself as module maintainer. See example.
Added myself and the module files to
.github/CODEOWNERS
.