fixes and cleanup

This commit is contained in:
[yuri]
2025-12-11 17:40:57 +01:00
parent 45e2380afe
commit 0d3eae000e
4 changed files with 1 additions and 416 deletions

View File

@@ -154,37 +154,9 @@ if [[ "${DE}" == "xfce" || "${DDE}" == "xfce" ]]; then
fi
fi
###############################################
# Copy settings to HOME
###############################################
SOURCE_DIR="$SCRIPT_DIR/config-files/arch"
DEST_DIR="$HOME"
# replace bashrc
say_yellow "Setting bashrc"
say_yellow "making backup of bashrc"
sudo cp -v /etc/skel/.bashrc /etc/skel/.bashrc.starburst
sudo cp -rf $SOURCE_DIR/.bashrc /etc/skel/.bashrc
sudo cp -rf $SOURCE_DIR/.bashrc $HOME/.bashrc
# 1. Verify source directory exists
if [ ! -d "$SOURCE_DIR" ]; then
echo "Error: Source directory '$SOURCE_DIR' not found. Skipping config."
# Use exit 1 if this is critical, or just exit 0 to continue the main script
# exit 1
fi
say_yellow "Applying configuration directly to $DEST_DIR..."
# 2. Use shopt for dotfiles, then copy recursively and forcefully
shopt -s dotglob
cp -vrf "$SOURCE_DIR"/* "$DEST_DIR"/
shopt -u dotglob
# 3. Clean up session cache if desired (e.g., if copying existing settings)
say_yellow "Clearing session cache..."
rm -rf "$HOME/.cache/sessions/"
say_yellow "configuration applied. User can log in now."
# End of script
say_green "Full setup completed."