Skip to content

Commit e7fa7d2

Browse files
committed
auto-sync: [Mon Jun 8 09:40:47 PM -03 2026]
1 parent adfbda5 commit e7fa7d2

2 files changed

Lines changed: 16 additions & 2 deletions

File tree

hypr/.config/hypr/hyprland.conf

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
$terminal = kitty
3434
$fileManager = dolphin
3535
$menu = rofi -show drun
36+
$codeWorkspace = kitty
3637

3738

3839
#################
@@ -49,7 +50,7 @@ exec-once = hyprpaper
4950
exec-once = nm-applet &
5051
exec-once = waybar &
5152
exec-once = systemctl --user start hyprpolkitagent
52-
exec-once = [workspace 1 silent] cursor
53+
exec-once = [workspace 1 silent] $codeWorkspace
5354
exec-once = [workspace 2 silent] vivaldi
5455
exec-once = [workspace 3 silent] bash -c "sleep 2 && /home/runner/.local/bin/scripts/betterbird.sh"
5556
exec-once = [workspace 4 silent] $HOME/.local/bin/Obsidian-1.11.5.AppImage
@@ -268,7 +269,7 @@ bind = SHIFT, Print, exec, grim -g "$(slurp)" - | wl-copy
268269
bind = CTRL, Print, exec, grim -g "$(slurp)" - | swappy -f -
269270

270271
# Example binds, see https://wiki.hypr.land/Configuring/Binds/ for more
271-
bind = $mainMod, U, exec, /home/runner/dotfiles/hypr/.config/hypr/scripts/summon_cursor.sh
272+
bind = $mainMod, U, exec, /home/runner/dotfiles/hypr/.config/hypr/scripts/summon_code-workspace.sh 1 $codeWorkspace
272273
bind = $mainMod, I, exec, /home/runner/dotfiles/hypr/.config/hypr/scripts/summon_vivaldi.sh
273274
bind = $mainMod, O, exec, /home/runner/dotfiles/hypr/.config/hypr/scripts/summon_betterbird.sh
274275
bind = $mainMod, P, exec, /home/runner/dotfiles/hypr/.config/hypr/scripts/summon_obsidian.sh
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#!/usr/bin/env bash
2+
WORKSPACE=$1
3+
CLASS=$2
4+
EXEC_CMD=${3:-$CLASS}
5+
6+
if hyprctl clients -j | jq -e ".[] | select(.class | match(\"(?i)$CLASS\"))" > /dev/null; then
7+
hyprctl dispatch movetoworkspacesilent "$WORKSPACE,class:.*(?i)$CLASS.*"
8+
hyprctl dispatch workspace "$WORKSPACE"
9+
hyprctl dispatch focuswindow "class:.*(?i)$CLASS.*"
10+
else
11+
hyprctl dispatch workspace "$WORKSPACE"
12+
hyprctl dispatch exec "$EXEC_CMD"
13+
fi

0 commit comments

Comments
 (0)