Script for coying copyy_stuff is made inline
This commit is contained in:
+11
-7
@@ -2909,20 +2909,24 @@ This makes sure all ./assets/copy_stuff ends up in the right folder
|
||||
#+begin_src nix :tangle home/copy_stuff.nix :noweb tangle :mkdirp yes.
|
||||
{ config, pkgs, lib, flakeRoot, ... }:
|
||||
{
|
||||
home.packages = [ pkgs.bash ];
|
||||
home.activation.recreateConfig = {
|
||||
text = ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
set -euo pipefail
|
||||
echo "Running post-activation script..."
|
||||
"${flakeRoot}/assets/scripts/recreate_config.sh"
|
||||
SOURCE_DIR="${flakeRoot}/assets/copy_stuff"
|
||||
DEST_DIR="$HOME"
|
||||
if [ ! -d "$SOURCE_DIR" ]; then
|
||||
echo "Error: Source directory $SOURCE_DIR does not exist."
|
||||
exit 1
|
||||
fi
|
||||
mkdir -p "$DEST_DIR"
|
||||
rsync -av --no-group --no-owner --delete "$SOURCE_DIR/" "$DEST_DIR/"
|
||||
echo "Config files copied from $SOURCE_DIR to $DEST_DIR. Symlinks replaced with editable files."
|
||||
hyprctl reload
|
||||
'';
|
||||
deps = [ pkgs.bash ];
|
||||
deps = [ pkgs.bash pkgs.rsync ];
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
|
||||
#+end_src
|
||||
|
||||
* README Utils
|
||||
|
||||
Reference in New Issue
Block a user