Add messages to install.sh, unify message format

This commit is contained in:
Franklyn Tackitt 2022-08-01 10:12:04 -07:00
parent 0d09922673
commit 7473fc8674
2 changed files with 7 additions and 3 deletions

4
install.sh Normal file → Executable file
View File

@ -1,19 +1,23 @@
#!/usr/bin/env bash #!/usr/bin/env bash
# Create required directories # Create required directories
echo ":: Creating required directories"
mkdir -p "$HOME/homebrew" mkdir -p "$HOME/homebrew"
mkdir -p "$HOME/.config/systemd/user" mkdir -p "$HOME/.config/systemd/user"
# Clone the startup animations repository # Clone the startup animations repository
if [[ ! -d "$HOME/homebrew/startup_animations" ]]; then if [[ ! -d "$HOME/homebrew/startup_animations" ]]; then
echo ":: Installing to $HOME/homebrew/startup_animations"
git clone https://github.com/kageurufu/steamdeck_startup_animations "$HOME/homebrew/startup_animations" git clone https://github.com/kageurufu/steamdeck_startup_animations "$HOME/homebrew/startup_animations"
cd "$HOME/homebrew/startup_animations" cd "$HOME/homebrew/startup_animations"
else else
echo ":: Updating $HOME/homebrew/startup_animations"
cd "$HOME/homebrew/startup_animations" cd "$HOME/homebrew/startup_animations"
git pull git pull
fi fi
# Install the service file # Install the service file
echo ":: Installing the startup service"
ln -sf "$HOME/homebrew/startup_animations/randomize_deck_startup.service" "$HOME/.config/systemd/user/randomize_deck_startup.service" ln -sf "$HOME/homebrew/startup_animations/randomize_deck_startup.service" "$HOME/.config/systemd/user/randomize_deck_startup.service"
systemctl --user daemon-reload systemctl --user daemon-reload
systemctl --user enable --now randomize_deck_startup.service systemctl --user enable --now randomize_deck_startup.service

6
uninstall.sh Normal file → Executable file
View File

@ -1,19 +1,19 @@
#!/usr/bin/env bash #!/usr/bin/env bash
if [[ -e "$HOME/.config/systemd/user/randomize_deck_startup.service" ]]; then if [[ -e "$HOME/.config/systemd/user/randomize_deck_startup.service" ]]; then
echo "Removing the boot service" echo ":: Removing the boot service"
systemctl --user disable randomize_deck_startup.service systemctl --user disable randomize_deck_startup.service
rm "$HOME/.config/systemd/user/randomize_deck_startup.service" rm "$HOME/.config/systemd/user/randomize_deck_startup.service"
fi fi
if [[ -f "$HOME/.steam/steam/steamui/movies/deck_startup.webm.backup" ]]; then if [[ -f "$HOME/.steam/steam/steamui/movies/deck_startup.webm.backup" ]]; then
echo "Restoring deck_startup.webm.backup" echo ":: Restoring deck_startup.webm.backup"
rm "$HOME/.steam/steam/steamui/movies/deck_startup.webm" rm "$HOME/.steam/steam/steamui/movies/deck_startup.webm"
mv "$HOME/.steam/steam/steamui/movies/deck_startup.webm.backup" "$HOME/.steam/steam/steamui/movies/deck_startup.webm" mv "$HOME/.steam/steam/steamui/movies/deck_startup.webm.backup" "$HOME/.steam/steam/steamui/movies/deck_startup.webm"
fi fi
if [[ -e "$HOME/homebrew/startup_animations" ]]; then if [[ -e "$HOME/homebrew/startup_animations" ]]; then
echo "Deleting the startup_animations directory" echo ":: Deleting the startup_animations directory"
rm -rf "$HOME/homebrew/startup_animations" rm -rf "$HOME/homebrew/startup_animations"
fi fi