diff options
| author | Martin Guzman <55927935+brockar@users.noreply.github.com> | 2026-01-21 16:18:43 -0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-01-21 16:18:43 -0300 |
| commit | c6198c1bedeffd08ec3f60f7ba3a41e6c5870885 (patch) | |
| tree | 458c030873b4e70ff9eda0baed5df257434871f4 /config/hypr/scripts/KooLsDotsUpdate.sh | |
| parent | 7dedbe3d4a4560ac15987fdf8164dbbb1f4701bf (diff) | |
| parent | 88a09344e8cc7cffe69a017eb752e8c6fa17ddcb (diff) | |
Merge pull request #927 from JaKooLit/development
Merge Development to main branch for release
Diffstat (limited to 'config/hypr/scripts/KooLsDotsUpdate.sh')
| -rwxr-xr-x | config/hypr/scripts/KooLsDotsUpdate.sh | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/config/hypr/scripts/KooLsDotsUpdate.sh b/config/hypr/scripts/KooLsDotsUpdate.sh index 51277ab1..a49f5430 100755 --- a/config/hypr/scripts/KooLsDotsUpdate.sh +++ b/config/hypr/scripts/KooLsDotsUpdate.sh @@ -5,12 +5,12 @@ # Local Paths local_dir="$HOME/.config/hypr" iDIR="$HOME/.config/swaync/images/" -local_version=$(ls $local_dir/v* 2>/dev/null | sort -V | tail -n 1 | sed 's/.*v\(.*\)/\1/') +local_version=$(find "$local_dir" -maxdepth 1 -name 'v*' -printf '%f\n' 2>/dev/null | sort -V | tail -n 1 | sed 's/^v//') KooL_Dots_DIR="$HOME/Hyprland-Dots" # exit if cannot find local version if [ -z "$local_version" ]; then - notify-send -i "$iDIR/error.png" "ERROR "!?!?!!"" "Unable to find KooL's dots version . exiting.... " + notify-send -i "$iDIR/error.png" 'ERROR !?!?!!' "Unable to find KooL's dots version. Exiting." exit 1 fi @@ -19,7 +19,7 @@ branch="main" github_url="https://github.com/JaKooLit/Hyprland-Dots/tree/$branch/config/hypr/" # Fetch the version from GitHub URL - KooL's dots -github_version=$(curl -s $github_url | grep -o 'v[0-9]\+\.[0-9]\+\.[0-9]\+' | sort -V | tail -n 1 | sed 's/v//') +github_version=$(curl -s "$github_url" | grep -o 'v[0-9]\+\.[0-9]\+\.[0-9]\+' | sort -V | tail -n 1 | sed 's/v//') # Cant find GitHub URL - KooL's dots version if [ -z "$github_version" ]; then @@ -39,13 +39,13 @@ else case "$response" in "action1") - if [ -d $KooL_Dots_DIR ]; then + if [ -d "$KooL_Dots_DIR" ]; then if ! command -v kitty &> /dev/null; then notify-send -i "$iDIR/error.png" "E-R-R-O-R" "Kitty terminal not found. Please install Kitty terminal." exit 1 fi kitty -e bash -c " - cd $KooL_Dots_DIR && + cd \"$KooL_Dots_DIR\" && git stash && git pull && ./copy.sh && @@ -59,7 +59,7 @@ else fi kitty -e bash -c " git clone --depth=1 https://github.com/JaKooLit/Hyprland-Dots.git $KooL_Dots_DIR && - cd $KooL_Dots_DIR && + cd \"$KooL_Dots_DIR\" && chmod +x copy.sh && ./copy.sh && notify-send -u critical -i "$iDIR/ja.png" 'Update Completed:' 'Kindly log out and relogin to take effect' |
