create install.sh and update README

This commit is contained in:
Guilhem Baccialone 2026-06-21 08:15:42 +02:00
parent 05c4a780d7
commit 49c53140e4
4 changed files with 53 additions and 9 deletions

35
install.sh Executable file
View file

@ -0,0 +1,35 @@
#!/bin/bash
# Check stow is installed
echo "Checking stow is installed"
if [[ $(which stow 2>/dev/null) ]]; then
echo "stow is installed!"
else
echo "stow is not installed, exiting…"
exit 1
fi
echo "Checking eza is installed"
if [[ $(which eza 2>/dev/null) ]]; then
echo "eza is installed!"
else
echo "eza is not installed, exiting…"
exit 1
fi
# Check the folder is deploy in $HOME
echo "Check the folder is deploy in $HOME"
path=$(dirname $(pwd))
if [[ "$path" != "$HOME" ]]; then
echo "dotfiles folder must be cloned in your /\$HOMEdirectory"
echo "exiting…"
exit 1
fi
echo "dotfiles folder is in the right place"
echo "Stowing dotfiles..."
for folder in $(eza -D)
do
stow "$folder"
done
echo "done!"