Added start- end end-scripts

This commit is contained in:
2026-03-03 11:09:56 +01:00
parent c71a881a0a
commit 40a3f7f471
4 changed files with 79 additions and 28 deletions
@@ -8,10 +8,8 @@ if [ ! -d "$SOURCE_DIR" ]; then
echo "Error: Source directory $SOURCE_DIR does not exist."
exit 1
fi
# Create destination directory if it doesn't exist
mkdir -p "$DEST_DIR"
# Use rsync to copy files, overwriting symlinks and existing files
# --delete removes files in DEST_DIR that are not in SOURCE_DIR
# --no-group --no-owner preserves your user ownership
rsync -av --no-group --no-owner --delete "$SOURCE_DIR/" "$DEST_DIR/"
rsync -av --no-group --no-owner "$SOURCE_DIR/" "$DEST_DIR/"
echo "Config files copied from $SOURCE_DIR to $DEST_DIR. Symlinks replaced with editable files."
+12
View File
@@ -0,0 +1,12 @@
#!/usr/bin/env bash
set -euo pipefail
# Example of how to execute a script
# Path to the script to execute
COPY_SCRIPT="./assets/scripts/copy_stuff.sh"
# Check if the script exists
if [ ! -f "$COPY_SCRIPT" ]; then
echo "Error: Script $COPY_SCRIPT does not exist."
exit 1
fi
# Execute the script
"$COPY_SCRIPT"
+12
View File
@@ -0,0 +1,12 @@
#!/usr/bin/env bash
set -euo pipefail
# Example of how to execute a script
# Path to the script to execute
#COPY_SCRIPT="./assets/scripts/copy_stuff.sh"
# Check if the script exists
#if [ ! -f "$COPY_SCRIPT" ]; then
# echo "Error: Script $COPY_SCRIPT does not exist."
#$ exit 1
#fi
# Execute the script
#"$COPY_SCRIPT"