Fix basename error in dotfiles installation
- Properly handle . and .. in dotfile copy loop - Change directory before listing to avoid path issues - Explicitly exclude . and .. from file copying 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
bb642474b7
commit
eb7a74e6fc
@ -92,10 +92,13 @@ echo "[+] Installing dotfiles..."
|
||||
su - ${ALMA_USER} -c '
|
||||
cd &&
|
||||
git clone https://git.dominik-roth.eu/dodox/nullpoint.git /tmp/nullpoint-dotfiles &&
|
||||
for file in /tmp/nullpoint-dotfiles/dotfiles/.*; do
|
||||
[ -f "$file" ] && cp "$file" . 2>/dev/null || true
|
||||
cd /tmp/nullpoint-dotfiles/dotfiles &&
|
||||
for file in .*; do
|
||||
if [ -f "$file" ] && [ "$file" != "." ] && [ "$file" != ".." ]; then
|
||||
cp "$file" ~/ 2>/dev/null || true
|
||||
fi
|
||||
done &&
|
||||
rm -rf /tmp/nullpoint-dotfiles
|
||||
cd && rm -rf /tmp/nullpoint-dotfiles
|
||||
' || echo "WARNING: dotfiles installation failed"
|
||||
|
||||
# Set up MOTD
|
||||
|
Loading…
Reference in New Issue
Block a user