-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathupdate.sh
More file actions
executable file
·33 lines (26 loc) · 896 Bytes
/
update.sh
File metadata and controls
executable file
·33 lines (26 loc) · 896 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/bash
# Usage: ./update.sh [--all]
# If --all is provided, it will also update common configuration files.
# Shortcut to install WebApps shortcuts and TUI shortcuts.
set -eE
# If current directory is a git repository, pull the latest changes
if [ -d .git ]; then
git pull
fi
# Add a confirmation prompt with gum since this will overwrite existing configuration files
if ! gum confirm "This will overwrite your existing configuration files. Do you want to continue?"; then
echo "Aborting."
exit 0
fi
# Must be on archlinux
if ! command -v pacman &> /dev/null; then
echo "This script is intended to be run on Arch Linux." >&2
exit 1
fi
if [ "$1" == "--all" ]; then
# Update common configuration files
source ./common/install/bootstrap.sh
setup
fi
# Update Tilling Niri (without reinstalling packages)
./archlinux/install/tilling/setup.sh --skip-packages