aboutsummaryrefslogtreecommitdiffstats
path: root/config/hypr/scripts
diff options
context:
space:
mode:
authorJa.KooLit <85185940+JaKooLit@users.noreply.github.com>2025-01-12 14:51:49 +0900
committerGitHub <noreply@github.com>2025-01-12 14:51:49 +0900
commit1a51c1c781bd92be657a9bb74685a86d9c76c733 (patch)
tree48d22a66e91b124f517ce52b5455a868d4cc982e /config/hypr/scripts
parentb0168284df23c1d5c4967685d814732f354ed8f6 (diff)
parent4a8b493fdb60ee5b055bb8cf4e9b26826e8ef5db (diff)
Merge pull request #516 from JaKooLit/main
Main to development
Diffstat (limited to 'config/hypr/scripts')
-rwxr-xr-xconfig/hypr/scripts/ClipManager.sh5
-rwxr-xr-xconfig/hypr/scripts/KeyBinds.sh5
-rwxr-xr-xconfig/hypr/scripts/Refresh.sh17
-rwxr-xr-xconfig/hypr/scripts/RofiEmoji.sh6
-rwxr-xr-xconfig/hypr/scripts/RofiSearch.sh2
-rwxr-xr-xconfig/hypr/scripts/SwitchKeyboardLayout.sh2
-rwxr-xr-xconfig/hypr/scripts/WaybarLayout.sh2
-rwxr-xr-xconfig/hypr/scripts/WaybarStyles.sh2
8 files changed, 33 insertions, 8 deletions
diff --git a/config/hypr/scripts/ClipManager.sh b/config/hypr/scripts/ClipManager.sh
index ddce2999..13f90a9e 100755
--- a/config/hypr/scripts/ClipManager.sh
+++ b/config/hypr/scripts/ClipManager.sh
@@ -6,6 +6,11 @@
# CTRL Del to delete an entry
# ALT Del to wipe clipboard contents
+# Check if rofi is already running
+if pidof rofi > /dev/null; then
+ pkill rofi
+fi
+
while true; do
result=$(
rofi -i -dmenu \
diff --git a/config/hypr/scripts/KeyBinds.sh b/config/hypr/scripts/KeyBinds.sh
index 4aca73d9..9e01a7c3 100755
--- a/config/hypr/scripts/KeyBinds.sh
+++ b/config/hypr/scripts/KeyBinds.sh
@@ -5,6 +5,11 @@
# Kill yad to not interfere with this binds
pkill yad || true
+# Check if rofi is already running
+if pidof rofi > /dev/null; then
+ pkill rofi
+fi
+
# Define the config files
KEYBINDS_CONF="$HOME/.config/hypr/configs/Keybinds.conf"
USER_KEYBINDS_CONF="$HOME/.config/hypr/UserConfigs/UserKeybinds.conf"
diff --git a/config/hypr/scripts/Refresh.sh b/config/hypr/scripts/Refresh.sh
index f5f91c34..78f76702 100755
--- a/config/hypr/scripts/Refresh.sh
+++ b/config/hypr/scripts/Refresh.sh
@@ -22,13 +22,11 @@ for _prs in "${_ps[@]}"; do
fi
done
+killall -SIGUSR2 waybar # added since wallust sometimes not applying
+
# quit ags
ags -q
-sleep 1
-#Restart waybar
-waybar &
-
# relaunch swaync
sleep 0.5
swaync > /dev/null 2>&1 &
@@ -36,6 +34,16 @@ swaync > /dev/null 2>&1 &
# relaunch ags
ags &
+# Kill waybar (yet again) # added since wallust sometimes not applying
+if pidof waybar >/dev/null; then
+ pkill waybar
+fi
+
+
+sleep 1
+#Restart waybar
+waybar &
+
# Relaunching rainbow borders if the script exists
sleep 1
if file_exists "${UserScripts}/RainbowBorders.sh"; then
@@ -43,4 +51,5 @@ if file_exists "${UserScripts}/RainbowBorders.sh"; then
fi
+
exit 0 \ No newline at end of file
diff --git a/config/hypr/scripts/RofiEmoji.sh b/config/hypr/scripts/RofiEmoji.sh
index 6bf6a5ab..fa27a341 100755
--- a/config/hypr/scripts/RofiEmoji.sh
+++ b/config/hypr/scripts/RofiEmoji.sh
@@ -2,6 +2,11 @@
# /* ---- 💫 https://github.com/JaKooLit 💫 ---- */ ##
# Rofi Emoticons. Not my own. Cant remember the source
+# Check if rofi is already running
+if pidof rofi > /dev/null; then
+ pkill rofi
+fi
+
sed '1,/^# # DATA # #$/d' "$0" | \
rofi -i -dmenu -config ~/.config/rofi/config-emoji.rasi | \
awk -F'\t' '{print $1}' | \
@@ -10,6 +15,7 @@ wl-copy
exit
+
# # DATA # #
😀 face face | grin | grinning face
😃 face with big eyes face | grinning face with big eyes | mouth | open | smile
diff --git a/config/hypr/scripts/RofiSearch.sh b/config/hypr/scripts/RofiSearch.sh
index 9b7e4bd4..ccc73016 100755
--- a/config/hypr/scripts/RofiSearch.sh
+++ b/config/hypr/scripts/RofiSearch.sh
@@ -9,7 +9,7 @@ rofi_config="$HOME/.config/rofi/config-search.rasi"
# Kill Rofi if already running before execution
if pgrep -x "rofi" >/dev/null; then
pkill rofi
- exit 0
+ #exit 0
fi
# Open rofi with a dmenu and pass the selected item to xdg-open for Google search
diff --git a/config/hypr/scripts/SwitchKeyboardLayout.sh b/config/hypr/scripts/SwitchKeyboardLayout.sh
index 76c06574..2d265e28 100755
--- a/config/hypr/scripts/SwitchKeyboardLayout.sh
+++ b/config/hypr/scripts/SwitchKeyboardLayout.sh
@@ -80,7 +80,7 @@ change_layout() {
fi
echo "Switching layout for $name to $new_layout..."
- hyprctl switchxkblayout "$name" next
+ hyprctl switchxkblayout "$name" "$next_index"
if [ $? -ne 0 ]; then
echo "Error while switching layout for $name." >&2
error_found=true
diff --git a/config/hypr/scripts/WaybarLayout.sh b/config/hypr/scripts/WaybarLayout.sh
index 36cbeb10..738d34f4 100755
--- a/config/hypr/scripts/WaybarLayout.sh
+++ b/config/hypr/scripts/WaybarLayout.sh
@@ -50,7 +50,7 @@ main() {
# Kill Rofi if already running before execution
if pgrep -x "rofi" >/dev/null; then
pkill rofi
- exit 0
+ #exit 0
fi
main
diff --git a/config/hypr/scripts/WaybarStyles.sh b/config/hypr/scripts/WaybarStyles.sh
index 95a348ba..096e4d7c 100755
--- a/config/hypr/scripts/WaybarStyles.sh
+++ b/config/hypr/scripts/WaybarStyles.sh
@@ -44,7 +44,7 @@ main() {
# Kill Rofi if already running before execution
if pgrep -x "rofi" >/dev/null; then
pkill rofi
- exit 0
+ #exit 0
fi
main
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage