custom-hypr - up to date config

This commit is contained in:
huyjaky
2024-10-26 23:40:04 +07:00
parent 7e1dc80f6d
commit e9f06c7d3e
84 changed files with 2436 additions and 70 deletions

View File

@@ -5,5 +5,8 @@ exec-once = corectrl
exec-once = otd-daemon # run driver veikk
exec-once = fcitx5
exec-once = waybar -c ~/.config/waybar/primary_screen/config.jsonc
exec-once = waybar -c ~/.config/waybar/secondary_screen/config.jsonc
exec = gsettings set org.gnome.desktop.interface icon-theme 'Nordzy'
exec = hyprctl setcursor Gruvbox-Retro 20

View File

@@ -17,6 +17,7 @@ workspace = 6, monitor:HDMI-A-1,
workspace = 8, monitor:HDMI-A-1,
workspace = 10, monitor:HDMI-A-1,
decoration {
blur {
enabled = false
@@ -50,6 +51,10 @@ general {
layout = master
}
master {
new_on_top = true
}
dwindle {
preserve_split = true # you probably want this
#no_gaps_when_only = true

View File

@@ -5,7 +5,6 @@
unbind = Super, W
unbind = Super, T
unbind = Alt, E
# disbale side
unbind = Super, B
unbind = Super, M
@@ -17,53 +16,51 @@ unbind = Super, H
unbind = Super, J
unbind = Super, K
unbind = Super, L
unbind = Ctrl+Alt, mouse_down
unbind = Ctrl+Alt, mouse_up
unbind = SUPER, mouse:273
# move windown
# move focus
bind = Alt, H, exec, source /home/duckq1u/.config/hypr/scripts/focusStateToLeft.sh # [hidden]
# bind = Alt, H, movefocus, l # [hidden]
bind = Alt, L, exec, source /home/duckq1u/.config/hypr/scripts/focusStateToRight.sh # [hidden]
# bind = Alt, L, movefocus, r # [hidden]
bind = Alt, K, fullscreenstate, 0 # [hidden]
bind = Alt, K, movefocus, u # [hidden]
bind = Alt, J, fullscreenstate, 0 # [hidden]
bind = Alt, J, movefocus, d # [hidden]
##! Window arrangement
#/# bind = Super+Shift, ←/↑/→/↓,, # Window: move in direction
##! Move window
bind = Ctrl+Alt, H, exec, source /home/duckq1u/.config/hypr/scripts/windowtoleft.sh # [hidden]
# bind = Ctrl+Alt, H, movewindow, l # [hidden]
# bind = Ctrl+Alt, L, fullscreenstate, 0 # [hidden]
bind = Ctrl+Alt, L, exec, source /home/duckq1u/.config/hypr/scripts/windowtoright.sh # [hidden]
bind = Ctrl+Alt, K, movewindow, u # [hidden]
bind = Ctrl+Alt, J, movewindow, d # [hidden]
# bind = Ctrl+Alt, M, exec, pavucontrol # Launch pavucontrol (volume mixer)
bind = Alt, Q, killactive,
bind = Alt, F, fullscreen, 1
# bind = Alt, R, exec, killall ags ydotool; ags & # Restart widgets
## switch workspace
bind = Shift+Alt, L, exec, source /home/duckq1u/.config/hypr/scripts/workspaceV2inscrease.sh
bind = Shift+Alt, H, exec, source /home/duckq1u/.config/hypr/scripts/workspaceV2descrease.sh
bindt = Ctrl+Alt, mouse:272, exec, source /home/duckq1u/.config/hypr/scripts/workspaceV2descrease.sh
bindt = Ctrl+Alt, mouse:273, exec, source /home/duckq1u/.config/hypr/scripts/workspaceV2inscrease.sh
bindm = ALT, mouse:272, movewindow # [hidden]
bind = Alt, Q, killactive,
bind = Alt, F, fullscreen, 1
bind = Shift+Alt, F, fullscreen, 0
bind = Alt, E, exec, nautilus --new-window # Launch Nautilus (file manager)
# bind = Alt, M, exec, ags run-js 'openMusicControls.value = (!mpris.getPlayer() ? false : !openMusicControls.value);' # Toggle music controls
# bind = Alt, N, exec, ags -t 'sideright' # Toggle right sidebar
bind = Alt, T, exec, kitty
bind = Alt, B, exec, brave
# bind = Alt, F, exec, rofi
bind = Alt, B, exec, thorium-browser
bind = Shift+Alt, B, exec, brave
bind = Alt, O, exec, obsidian --no-sandbox --ozone-platform=wayland --ozone-platform-hint=auto --enable-features=UseOzonePlatform,WaylandWindowDecorations %U
bind = Alt, V, exec, vesktop --no-sandbox --ozone-platform=wayland --ozone-platform-hint=auto --enable-features=UseOzonePlatform,WaylandWindowDecorations %U
bind = SUPER, SUPER_L, exec, pkill -x rofi || $scrPath/rofilaunch.sh d # launch application launcher
bind = Ctrl+SUPER, Ctrl+SUPER_L, exec, rofi
bind = Shift+Alt, L, exec, source /home/duckq1u/.config/hypr/scripts/workspaceV2inscrease.sh
bind = Shift+Alt, H, exec, source /home/duckq1u/.config/hypr/scripts/workspaceV2descrease.sh
bind = Alt, S, exec, volumecontrol.sh -s ''
bind = Alt, M, exec, volumecontrol.sh -s ''
$mainMod = Super # super / meta / windows key
$scrPath = $HOME/.local/share/bin # set scripts path

View File

@@ -1,4 +1,5 @@
windowrulev2 = bordercolor rgb(FF0000) rgb(880808),fullscreen:1
# windowrule = fullscreen unset

View File

@@ -29,7 +29,7 @@ exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CUR
exec-once = dbus-update-activation-environment --systemd --all # for XDPH
exec-once = systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP # for XDPH
exec-once = $scrPath/polkitkdeauth.sh # authentication dialogue for GUI apps
exec-once = waybar # launch the system bar
# exec-once = waybar # launch the system bar
exec-once = blueman-applet # systray app for Bluetooth
exec-once = udiskie --no-automount --smart-tray # front-end that allows to manage removable media
exec-once = nm-applet --indicator # systray app for Network/Wifi

View File

@@ -12,3 +12,4 @@ if [ $window_state -eq 1 ]; then
fi
hyprctl dispatch movefocus l
exit 0

View File

@@ -15,3 +15,4 @@ if [ $window_state -eq 1 ]; then
fi
hyprctl dispatch movefocus r
exit 0

View File

@@ -25,10 +25,10 @@ if [ $window_x_position -eq 14 ] && [ $window_state -eq 1 ]; then
if [ $current_workspace -eq 1 ]; then
exit 1
fi
hyprctl dispatch movetoworkspace $((window_at_workspace-1))
hyprctl dispatch focusmonitor 0
hyprctl dispatch workspace $((current_workspace-2))
hyprctl dispatch focusmonitor 1
hyprctl dispatch movetoworkspace $((window_at_workspace-1)) \
&& hyprctl dispatch focusmonitor 0 \
&& hyprctl dispatch workspace $((current_workspace-2)) \
&& hyprctl dispatch focusmonitor 1
exit 0
fi
@@ -37,10 +37,10 @@ if [ $window_x_position -eq 14 ] && [ $window_width -eq 1892 ]; then
if [ $current_workspace -eq 1 ]; then
exit 1
fi
hyprctl dispatch movetoworkspace $((window_at_workspace-1))
hyprctl dispatch focusmonitor 0
hyprctl dispatch workspace $((current_workspace-2))
hyprctl dispatch focusmonitor 1
hyprctl dispatch movetoworkspace $((window_at_workspace-1)) \
&& hyprctl dispatch focusmonitor 0 \
&& hyprctl dispatch workspace $((current_workspace-2)) \
&& hyprctl dispatch focusmonitor 1
exit 0
fi
@@ -50,12 +50,13 @@ if [ $window_x_position -eq 14 ]; then
if [ $current_workspace -eq 1 ]; then
exit 1
fi
hyprctl dispatch movetoworkspace $((window_at_workspace-1))
hyprctl dispatch focusmonitor 0
hyprctl dispatch workspace $((current_workspace-2))
hyprctl dispatch focusmonitor 1
hyprctl dispatch movetoworkspace $((window_at_workspace-1)) \
&& hyprctl dispatch focusmonitor 0 \
&& hyprctl dispatch workspace $((current_workspace-2)) \
&& hyprctl dispatch focusmonitor 1
exit 0
fi
# Nếu không thoả điều kiện di chuyển, di chuyển cửa sổ sang phải
hyprctl dispatch movewindow l
exit 0

View File

@@ -1,5 +1,4 @@
#!/bin/bash
# Lấy thông tin của cửa sổ hiện tại chỉ một lần
window_info=$(hyprctl activewindow)
@@ -25,10 +24,10 @@ if [ $window_x_position -eq 1934 ] && [ $window_state -eq 1 ]; then
if [ $current_workspace -eq 6 ]; then
exit 1
fi
hyprctl dispatch movetoworkspace $((window_at_workspace+1))
hyprctl dispatch focusmonitor 1
hyprctl dispatch workspace $((current_workspace+2))
hyprctl dispatch focusmonitor 0
hyprctl dispatch movetoworkspace $((window_at_workspace+1)) \
&& hyprctl dispatch focusmonitor 1 \
&& hyprctl dispatch workspace $((current_workspace+2)) \
&& hyprctl dispatch focusmonitor 0
exit 0
fi
@@ -37,10 +36,10 @@ if [ $window_x_position -eq 1934 ] && [ $window_width -eq 1892 ]; then
if [ $current_workspace -eq 6 ]; then
exit 1
fi
hyprctl dispatch movetoworkspace $((window_at_workspace+1))
hyprctl dispatch focusmonitor 1
hyprctl dispatch workspace $((current_workspace+2))
hyprctl dispatch focusmonitor 0
hyprctl dispatch movetoworkspace $((window_at_workspace+1)) \
&& hyprctl dispatch focusmonitor 1 \
&& hyprctl dispatch workspace $((current_workspace+2)) \
&& hyprctl dispatch focusmonitor 0
exit 0
fi
@@ -50,12 +49,13 @@ if [ $window_x_position -eq 2990 ]; then
if [ $current_workspace -eq 6 ]; then
exit 1
fi
hyprctl dispatch movetoworkspace $((window_at_workspace+1))
hyprctl dispatch focusmonitor 1
hyprctl dispatch workspace $((current_workspace+2))
hyprctl dispatch focusmonitor 0
hyprctl dispatch movetoworkspace $((window_at_workspace+1)) \
&& hyprctl dispatch focusmonitor 1 \
&& hyprctl dispatch workspace $((current_workspace+2)) \
&& hyprctl dispatch focusmonitor 0
exit 0
fi
# Nếu không thoả điều kiện di chuyển, di chuyển cửa sổ sang phải
hyprctl dispatch movewindow r
exit 0

View File

@@ -26,13 +26,10 @@ if [ "$primary_monitor_workspace" -le 0 ] || [ "$secondary_monitor_workspace" -g
fi
hyprctl dispatch fullscreenstate 0 # minimize trước khi di chuyển
# Switch focus and workspace for both monitors
hyprctl dispatch focusmonitor 0
hyprctl dispatch workspace $primary_monitor_workspace
hyprctl dispatch focusmonitor 1
hyprctl dispatch workspace $secondary_monitor_workspace
# Optionally focus back to the original monitor if desired (adjust this part if needed)
hyprctl dispatch focusmonitor $current_monitor
hyprctl dispatch fullscreenstate 0 \
&&hyprctl dispatch focusmonitor 1 \
&&hyprctl dispatch workspace $primary_monitor_workspace \
&&hyprctl dispatch focusmonitor 0 \
&&hyprctl dispatch workspace $secondary_monitor_workspace \
&&hyprctl dispatch focusmonitor $current_monitor \
exit 0

View File

@@ -25,14 +25,12 @@ if [ "$primary_monitor_workspace" -le 0 ] || [ "$secondary_monitor_workspace" -g
exit 1
fi
hyprctl dispatch fullscreenstate 0 \
&&hyprctl dispatch focusmonitor 0 \
&&hyprctl dispatch workspace $primary_monitor_workspace \
&&hyprctl dispatch focusmonitor 1 \
&&hyprctl dispatch workspace $secondary_monitor_workspace \
&&hyprctl dispatch focusmonitor $current_monitor
exit 0
hyprctl dispatch fullscreenstate 0 # minimize trước khi di chuyển
# Switch focus and workspace for both monitors
hyprctl dispatch focusmonitor 0
hyprctl dispatch workspace $primary_monitor_workspace
hyprctl dispatch focusmonitor 1
hyprctl dispatch workspace $secondary_monitor_workspace
# Optionally focus back to the original monitor if desired (adjust this part if needed)
hyprctl dispatch focusmonitor $current_monitor

View File

@@ -53,9 +53,15 @@
windowrulev2 = float,class:^(org.kde.dolphin)$,title:^(Progress Dialog — Dolphin)$
windowrulev2 = float,class:^(org.kde.dolphin)$,title:^(Copying — Dolphin)$
windowrulev2 = float,title:^(About Mozilla Firefox)$
windowrulev2 = float,class:^(brave)$,title:^(Picture-in-Picture)$
windowrulev2 = float,class:^(brave)$,title:^(Library)$
windowrulev2 = float,class:^(firefox)$,title:^(Picture-in-Picture)$
windowrulev2 = float,class:^(firefox)$,title:^(Library)$
windowrulev2 = float,class:^(kitty)$,title:^(top)$
windowrulev2 = float,class:^(kitty)$,title:^(btop)$
windowrulev2 = float,class:^(kitty)$,title:^(htop)$