Regenerated
This commit is contained in:
+14
-12
@@ -292,24 +292,26 @@ This copies stuff to the user home-folder
|
||||
let
|
||||
username = config.defaultUser or "henrov";
|
||||
|
||||
# Include the asset folder in the Nix store
|
||||
# Include the source folder in the Nix store
|
||||
assetPath = builtins.path { path = ../../../assets/copy_2_home; };
|
||||
in
|
||||
{
|
||||
_module.args.hmUsers = {
|
||||
${username} = {
|
||||
home.activation.copyAssets = lib.hm.dag.entryAfter [ "writeBoundary" ] ''
|
||||
echo "Copying assets to home directory..."
|
||||
# Ensure this user entry merges safely with other modules
|
||||
${username} = lib.mkMerge [
|
||||
# Any previous _module.args.hmUsers.${username} entries from other modules will merge automatically
|
||||
{
|
||||
# Activation script to copy all assets into $HOME
|
||||
home.activation.copyAssets = lib.hm.dag.entryAfter [ "writeBoundary" ] ''
|
||||
echo "Copying assets from ${assetPath} to home directory..."
|
||||
|
||||
# List files for debug
|
||||
ls -la ${assetPath}
|
||||
# Copy recursively, overwrite existing files, leave other files untouched
|
||||
cp -rT ${assetPath} "$HOME"
|
||||
|
||||
# Copy recursively, overwrite existing, keep others intact
|
||||
cp -rT ${assetPath} "$HOME"
|
||||
|
||||
echo "Done copying assets."
|
||||
'';
|
||||
};
|
||||
echo "Done copying assets."
|
||||
'';
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
||||
#+END_SRC
|
||||
|
||||
Reference in New Issue
Block a user