From 29c6eb1d2d37fbf30cffe6b37c4de7f9d20df194 Mon Sep 17 00:00:00 2001 From: niacdoial Date: Sun, 18 Sep 2022 15:57:10 +0200 Subject: [PATCH] Files: Add symlinkJoin to documentation Doing so helps newcommers to overcome the "targets are unique among home.file directives" restriction with what tools already exist --- modules/lib/file-type.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/modules/lib/file-type.nix b/modules/lib/file-type.nix index cc23292b..f4719cd9 100644 --- a/modules/lib/file-type.nix +++ b/modules/lib/file-type.nix @@ -25,6 +25,13 @@ in defaultText = literalExpression ""; description = '' Path to target file relative to ${basePathDesc}. + + Please note that only a single + directive + may write to a given target. + In order to link several directories to the same place, you may use + symlinkJoin as such: + source = pkgs.symlinkJoin{name="myjoin"; dirs=[ home-package /some/path ]; postBuild="echo custom shell script here";}; ''; };