更新hyprland配置
This commit is contained in:
@@ -26,39 +26,21 @@ monitor = ,preferred,auto,auto
|
||||
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||
# Execute your favorite apps at launch
|
||||
|
||||
exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP # for XDPH
|
||||
exec-once = systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP # for XDPH
|
||||
exec-once = /usr/lib/polkit-kde-authentication-agent-1 # authentication dialogue for GUI apps
|
||||
exec-once = waybar # launch the system panel
|
||||
exec-once = blueman-applet # systray app for BT
|
||||
exec-once = nm-applet --indicator # systray app for Network/Wifi
|
||||
exec-once = mako # start notification demon
|
||||
exec-once = wl-paste --type text --watch cliphist store # clipboard store text data
|
||||
exec-once = wl-paste --type image --watch cliphist store # clipboard store image data
|
||||
exec-once = ~/.config/swww/swwwallpaper.sh # start wallpaper daemon
|
||||
exec-once = fcitx5 -d -r
|
||||
# exec-once = nm-applet --indicator # systray app for Network/Wifi
|
||||
# exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP # for XDPH
|
||||
# exec-once = systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP # for XDPH
|
||||
# exec-once = /usr/lib/polkit-kde-authentication-agent-1 # authentication dialogue for GUI apps
|
||||
# exec-once = wl-paste --type text --watch cliphist store # clipboard store text data
|
||||
# exec-once = wl-paste --type image --watch cliphist store # clipboard store image data
|
||||
# exec-once = ~/.config/swww/swwwallpaper.sh # start wallpaper daemon
|
||||
#exec-once = swayidle -w timeout 900 'hyprctl dispatch dpms off' resume 'hyprctl dispatch dpms on' # turn off monitor after 15 mins
|
||||
|
||||
|
||||
|
||||
# █▀▀ █▄░█ █░█
|
||||
# ██▄ █░▀█ ▀▄▀
|
||||
|
||||
# Some default env vars.
|
||||
|
||||
# env = XDG_CURRENT_DESKTOP,Hyprland
|
||||
# env = XDG_SESSION_TYPE,wayland
|
||||
# env = XDG_SESSION_DESKTOP,Hyprland
|
||||
# env = GDK_BACKEND,wayland
|
||||
# env = QT_QPA_PLATFORM,wayland
|
||||
# #env = QT_STYLE_OVERRIDE,kvantum
|
||||
# env = QT_QPA_PLATFORMTHEME,qt5ct
|
||||
# env = QT_WAYLAND_DISABLE_WINDOWDECORATION,1
|
||||
# env = QT_AUTO_SCREEN_SCALE_FACTOR,1
|
||||
# env = XDG_PICTURES_DIR,$HOME/Pictures
|
||||
|
||||
|
||||
|
||||
# █ █▄░█ █▀█ █░█ ▀█▀
|
||||
# █ █░▀█ █▀▀ █▄█ ░█░
|
||||
|
||||
@@ -81,15 +63,6 @@ input {
|
||||
numlock_by_default = true
|
||||
}
|
||||
|
||||
# Example per-device config
|
||||
# See https://wiki.hyprland.org/Configuring/Keywords/#executing for more
|
||||
|
||||
#device:epic mouse V1 {
|
||||
# sensitivity = -0.5
|
||||
#}
|
||||
|
||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||
|
||||
gestures {
|
||||
workspace_swipe = true
|
||||
workspace_swipe_fingers = 3
|
||||
@@ -97,23 +70,6 @@ gestures {
|
||||
|
||||
|
||||
|
||||
# █░░ ▄▀█ █▄█ █▀█ █░█ ▀█▀ █▀
|
||||
# █▄▄ █▀█ ░█░ █▄█ █▄█ ░█░ ▄█
|
||||
|
||||
# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
|
||||
|
||||
dwindle {
|
||||
pseudotile = yes # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below
|
||||
preserve_split = yes # you probably want this
|
||||
}
|
||||
|
||||
# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
|
||||
|
||||
#master {
|
||||
# new_is_master = true
|
||||
#}
|
||||
|
||||
|
||||
|
||||
# █▀▄▀█ █ █▀ █▀▀
|
||||
# █░▀░█ █ ▄█ █▄▄
|
||||
@@ -139,5 +95,4 @@ source = ~/.config/hypr/theme.conf
|
||||
source = ~/.config/hypr/monitors.conf # initially empty, to be configured by user and remains static
|
||||
source = ~/.config/hypr/userprefs.conf # initially empty, to be configured by user and remains static
|
||||
|
||||
# Note: as userprefs.conf is sourced at the end, settings configured in this file will override the defaults
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ $filemanager = dolphin
|
||||
################################################
|
||||
# Main actions
|
||||
################################################
|
||||
bind = $mainMod, C, exec, ~/.config/hypr/scripts/dontkillsteam.sh # killactive, # kill the window on focus
|
||||
bind = $mainMod, C, killactive # killactive, kill the window on focus
|
||||
bind = $mainMod CTRL, delete, exit, # kill hyperland session
|
||||
bind = $mainMod, F, togglefloating, # toggle the window on focus to float
|
||||
bind = $mainMod CTRL, L, exec, swaylock # lock screen
|
||||
@@ -36,30 +36,25 @@ bind = $mainMod, V, exec, code # open vscode
|
||||
# Rofi is toggled on/off if you repeat the key presses
|
||||
bind = $mainMod, SPACE, exec, pkill rofi || rofi -show drun # launch desktop applications
|
||||
bind = $mainMod, tab, exec, pkill rofi || rofi -show window # switch between desktop applications
|
||||
bind = $mainMod, D, exec, pkill rofi || rofi -show filebrowser # browse system files
|
||||
bind = $mainMod, E, exec, pkill rofi || rofi -show filebrowser # browse system files
|
||||
bind = $mainMod, R, exec, pkill rofi || rofi -show run # run a command
|
||||
|
||||
# Audio control
|
||||
# bind = , F10, exec, ~/.config/hypr/scripts/volumecontrol.sh -o m # toggle audio mute
|
||||
# binde = , F11, exec, ~/.config/hypr/scripts/volumecontrol.sh -o d # decrease volume
|
||||
# binde = , F12, exec, ~/.config/hypr/scripts/volumecontrol.sh -o i # increase volume
|
||||
bind = , XF86AudioMute, exec, ~/.config/hypr/scripts/volumecontrol.sh -o m # toggle audio mute
|
||||
bind = , XF86AudioMicMute, exec, ~/.config/hypr/scripts/volumecontrol.sh -i m # toggle microphone mute
|
||||
binde = , XF86AudioLowerVolume, exec, ~/.config/hypr/scripts/volumecontrol.sh -o d # decrease volume
|
||||
binde = , XF86AudioRaiseVolume, exec, ~/.config/hypr/scripts/volumecontrol.sh -o i # increase volume
|
||||
bind = , XF86AudioMute, exec, pamixer -t # toggle audio mute
|
||||
bind = , XF86AudioMicMute, exec, pamixer --default-source -t # toggle microphone mute
|
||||
binde = , XF86AudioLowerVolume, exec, pamixer -d 2# decrease volume
|
||||
binde = , XF86AudioRaiseVolume, exec, pamixer -i 2# increase volume
|
||||
bind = , XF86AudioPlay, exec, playerctl play-pause
|
||||
bind = , XF86AudioPause, exec, playerctl play-pause
|
||||
bind = , XF86AudioNext, exec, playerctl next
|
||||
bind = , XF86AudioPrev, exec, playerctl previous
|
||||
|
||||
# Brightness control
|
||||
binde = , XF86MonBrightnessUp, exec, ~/.config/hypr/scripts/brightnesscontrol.sh i # increase brightness
|
||||
binde = , XF86MonBrightnessDown, exec, ~/.config/hypr/scripts/brightnesscontrol.sh d # decrease brightness
|
||||
|
||||
# Screenshot/screencapture
|
||||
bind = , PRINT, exec, hyprshot -m window # logout menu
|
||||
bind = ALT, PRINT, exec, hyprshot -m region # logout menu
|
||||
bind = $CONTROL SHIFT, P, pass, ^(com\.obsproject\.Studio)$ # start/stop obs screen recording
|
||||
bind = , PRINT, exec, hyprshot -m window
|
||||
bind = ALT, PRINT, exec, hyprshot -m region
|
||||
|
||||
|
||||
################################################
|
||||
@@ -74,10 +69,13 @@ bind = $mainMod, G, exec, ~/.config/hypr/scripts/gamemode.sh # disable hypr effe
|
||||
################################################
|
||||
# Move focus with mainMod + arrow keys
|
||||
bind = $mainMod, left, movefocus, l
|
||||
bind = $mainMod, H, movefocus, l
|
||||
bind = $mainMod, right, movefocus, r
|
||||
bind = $mainMod, L, movefocus, r
|
||||
bind = $mainMod, up, movefocus, u
|
||||
bind = $mainMod, K, movefocus, u
|
||||
bind = $mainMod, down, movefocus, d
|
||||
bind = ALT, Tab, movefocus, d
|
||||
bind = $mainMod, J, movefocus, d
|
||||
|
||||
# Resize windows
|
||||
binde = $mainMod CONTROL, right, resizeactive, 10 0
|
||||
@@ -142,5 +140,7 @@ bind = $mainMod CONTROL, S, togglespecialworkspace,
|
||||
# Scroll through existing workspaces with mainMod + scroll
|
||||
bind = $mainMod CTRL, right, workspace, e+1
|
||||
bind = $mainMod, mouse_up, workspace, e+1
|
||||
bind = ALT, Tab, workspace, e+1
|
||||
|
||||
bind = $mainMod CTRL, left, workspace, e-1
|
||||
bind = $mainMod, mouse_down, workspace, e-1
|
||||
@@ -1,42 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
ncolor="-h string:bgcolor:#343d46 -h string:fgcolor:#c0c5ce -h string:frcolor:#c0c5ce"
|
||||
|
||||
function send_notification {
|
||||
brightness=`brightnessctl info | grep -oP "(?<=\()\d+(?=%)" | cat`
|
||||
brightinfo=$(brightnessctl info | awk -F"'" '/Device/ {print $2}')
|
||||
|
||||
angle="$(((($brightness + 2) / 5) * 5))"
|
||||
ico="~/.config/dunst/icons/vol/vol-${angle}.svg"
|
||||
bar=$(seq -s "." $(($brightness / 15)) | sed 's/[0-9]//g')
|
||||
|
||||
if [ $brightness -ne 0 ]; then
|
||||
notify-send $ncolor "brightctl" -i $ico -a "$brightness$bar" "Device: $brightinfo" -r 91190 -t 800
|
||||
|
||||
else
|
||||
notify-send -i $ico "Brightness: ${brightness}%" -a "$brightinfo" -u low -r 91190 -t 800
|
||||
fi
|
||||
|
||||
}
|
||||
|
||||
function get_brightness {
|
||||
brightnessctl -m | grep -o '[0-9]\+%' | head -c-2
|
||||
}
|
||||
|
||||
case $1 in
|
||||
i)
|
||||
# increase the backlight by 5%
|
||||
brightnessctl set +5%
|
||||
send_notification
|
||||
;;
|
||||
d)
|
||||
if [[ $(get_brightness) -lt 5 ]]; then
|
||||
# avoid 0% brightness
|
||||
brightnessctl set 1%
|
||||
else
|
||||
# decrease the backlight by 5%
|
||||
brightnessctl set 5%-
|
||||
fi
|
||||
send_notification
|
||||
;;
|
||||
esac
|
||||
@@ -1,5 +0,0 @@
|
||||
if [[ $(hyprctl activewindow -j | jq -r ".class") == "Steam" ]]; then
|
||||
xdotool windowunmap $(xdotool getactivewindow)
|
||||
else
|
||||
hyprctl dispatch killactive ""
|
||||
fi
|
||||
@@ -1,76 +0,0 @@
|
||||
#!/usr/bin/env sh
|
||||
|
||||
|
||||
# define functions
|
||||
|
||||
function print_error
|
||||
{
|
||||
cat << "EOF"
|
||||
./volumecontrol.sh -[device] <action>
|
||||
...valid device are...
|
||||
i -- [i]nput decive
|
||||
o -- [o]utput device
|
||||
...valid actions are...
|
||||
i -- <i>ncrease volume [+5]
|
||||
d -- <d>ecrease volume [-5]
|
||||
m -- <m>ute [x]
|
||||
EOF
|
||||
exit 1
|
||||
}
|
||||
|
||||
function notify_vol
|
||||
{
|
||||
vol=`pamixer $srce --get-volume | cat`
|
||||
angle="$(( (($vol+2)/5) * 5 ))"
|
||||
ico="${icodir}/vol-${angle}.svg"
|
||||
bar=$(seq -s "." $(($vol / 15)) | sed 's/[0-9]//g')
|
||||
notify-send $ncolor "volctl" -a "$vol$bar" "$nsink" -i $ico -r 91190 -t 800
|
||||
}
|
||||
|
||||
function notify_mute
|
||||
{
|
||||
mute=`pamixer $srce --get-mute | cat`
|
||||
if [ "$mute" == "true" ] ; then
|
||||
notify-send $ncolor "volctl" -a "muted" "$nsink" -i ${icodir}/muted-${dvce}.svg -r 91190 -t 800
|
||||
else
|
||||
notify-send $ncolor "volctl" -a "unmuted" "$nsink" -i ${icodir}/unmuted-${dvce}.svg -r 91190 -t 800
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
# set device source
|
||||
|
||||
while getopts io SetSrc
|
||||
do
|
||||
case $SetSrc in
|
||||
i) nsink=$(pamixer --list-sources | grep "_input." | head -1 | awk -F '" "' '{print $NF}' | sed 's/"//')
|
||||
srce="--default-source"
|
||||
dvce="mic" ;;
|
||||
o) nsink=$(pamixer --get-default-sink | grep "_output." | awk -F '" "' '{print $NF}' | sed 's/"//')
|
||||
srce=""
|
||||
dvce="speaker" ;;
|
||||
esac
|
||||
done
|
||||
|
||||
if [ $OPTIND -eq 1 ] ; then
|
||||
print_error
|
||||
fi
|
||||
|
||||
|
||||
# set device action
|
||||
|
||||
shift $((OPTIND -1))
|
||||
step="${2:-5}"
|
||||
icodir="~/.config/dunst/icons/vol"
|
||||
ncolor="-h string:bgcolor:#343d46 -h string:fgcolor:#c0c5ce -h string:frcolor:#c0c5ce"
|
||||
|
||||
case $1 in
|
||||
i) pamixer $srce -i ${step}
|
||||
notify_vol ;;
|
||||
d) pamixer $srce -d ${step}
|
||||
notify_vol ;;
|
||||
m) pamixer $srce -t
|
||||
notify_mute ;;
|
||||
*) print_error ;;
|
||||
esac
|
||||
|
||||
@@ -1,20 +1,13 @@
|
||||
exec = hyprctl setcursor Bibata-Modern-Ice 20
|
||||
exec = gsettings set org.gnome.desktop.interface cursor-theme 'Bibata-Modern-Ice'
|
||||
exec = gsettings set org.gnome.desktop.interface cursor-size 20
|
||||
|
||||
exec = kvantummanager --set Catppuccin-Latte
|
||||
exec = gsettings set org.gnome.desktop.interface icon-theme 'Tela-circle-grey'
|
||||
exec = gsettings set org.gnome.desktop.interface gtk-theme 'Catppuccin-Latte'
|
||||
exec = gsettings set org.gnome.desktop.interface color-scheme 'prefer-light'
|
||||
# █░░ ▄▀█ █▄█ █▀█ █░█ ▀█▀ █▀
|
||||
# █▄▄ █▀█ ░█░ █▄█ █▄█ ░█░ ▄█
|
||||
|
||||
exec = gsettings set org.gnome.desktop.interface font-name 'Cantarell 10'
|
||||
exec = gsettings set org.gnome.desktop.interface document-font-name 'Cantarell 10'
|
||||
exec = gsettings set org.gnome.desktop.interface monospace-font-name 'CaskaydiaCove Nerd Font Mono 9'
|
||||
exec = gsettings set org.gnome.desktop.interface font-antialiasing 'rgba'
|
||||
exec = gsettings set org.gnome.desktop.interface font-hinting 'full'
|
||||
# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
|
||||
|
||||
env = XCURSOR_THEME,Bibata-Modern-Ice
|
||||
env = XCURSOR_SIZE,20
|
||||
dwindle {
|
||||
pseudotile = yes # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below
|
||||
preserve_split = yes # you probably want this
|
||||
}
|
||||
|
||||
general {
|
||||
gaps_in = 2
|
||||
@@ -37,5 +30,3 @@ decoration {
|
||||
xray = false
|
||||
}
|
||||
}
|
||||
|
||||
blurls = waybar
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"layer": "top",
|
||||
"position": "top",
|
||||
"mod": "dock",
|
||||
"height": 28,
|
||||
"height": 30,
|
||||
"exclusive": true,
|
||||
"passthrough": false,
|
||||
"gtk-layer-shell": true,
|
||||
@@ -32,7 +32,6 @@
|
||||
"network",
|
||||
"bluetooth",
|
||||
"wireplumber",
|
||||
"wireplumber#microphone",
|
||||
"custom/power",
|
||||
"custom/rr"
|
||||
],
|
||||
@@ -178,32 +177,10 @@
|
||||
"format": "{icon} {volume}",
|
||||
"format-muted": "",
|
||||
"on-click": "pavucontrol -t 3",
|
||||
"on-click-middle": "~/.config/hypr/scripts/volumecontrol.sh -o m",
|
||||
"on-scroll-up": "~/.config/hypr/scripts/volumecontrol.sh -o i",
|
||||
"on-scroll-down": "~/.config/hypr/scripts/volumecontrol.sh -o d",
|
||||
"on-click-middle": "pamixer -t",
|
||||
"tooltip-format": "{icon} {desc} // {volume}%",
|
||||
"scroll-step": 5,
|
||||
"format-icons": {
|
||||
"headphone": "",
|
||||
"hands-free": "",
|
||||
"headset": "",
|
||||
"phone": "",
|
||||
"portable": "",
|
||||
"car": "",
|
||||
"default": ["", "", ""]
|
||||
}
|
||||
},
|
||||
|
||||
"wireplumber#microphone": {
|
||||
"format": "{format_source}",
|
||||
"format-source": "",
|
||||
"format-source-muted": "",
|
||||
"on-click": "c -t 4",
|
||||
"on-click-middle": "~/.config/hypr/scripts/volumecontrol.sh -i m",
|
||||
"on-scroll-up": "~/.config/hypr/scripts/volumecontrol.sh -i i",
|
||||
"on-scroll-down": "~/.config/hypr/scripts/volumecontrol.sh -i d",
|
||||
"tooltip-format": "{format_source} {source_desc} // {source_volume}%",
|
||||
"scroll-step": 5
|
||||
"scroll-step": 2,
|
||||
"format-icons": ["", "", ""]
|
||||
},
|
||||
|
||||
// modules for padding //
|
||||
|
||||
@@ -58,6 +58,13 @@
|
||||
"image/jpeg" = [ "imv.desktop" ];
|
||||
"image/png" = [ "imv.desktop" ];
|
||||
"image/webp" = [ "imv.desktop" ];
|
||||
|
||||
"inode/directory" = [ ]
|
||||
++ (if config.xdg.enable then [ "xdg-open.desktop" ] else [ ])
|
||||
++ (if config.xdg.enable then [ "nemo.desktop" ] else [ ])
|
||||
++ (if config.xdg.enable then [ "thunar.desktop" ] else [ ])
|
||||
++ (if config.xdg.enable then [ "nemo.desktop" ] else [ ])
|
||||
++ (if config.xdg.enable then [ "org.gnome.Nautilus.desktop" ] else [ ]);
|
||||
};
|
||||
|
||||
associations.removed =
|
||||
|
||||
@@ -6,5 +6,6 @@
|
||||
|
||||
home.packages = with pkgs; [
|
||||
nextcloud-client
|
||||
kodi-wayland
|
||||
];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user