Compare commits
8 Commits
3db24e33d4
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
88cca79368
|
|||
|
5857d4a0ed
|
|||
|
7f9b095859
|
|||
|
6d3b2e7445
|
|||
|
5c84263502
|
|||
|
469aa14b5d
|
|||
|
cc3ceda272
|
|||
|
9287396d75
|
@@ -1,4 +1,4 @@
|
||||
#? Config file for btop v. 1.4.4
|
||||
#? Config file for btop v. 1.4.5
|
||||
|
||||
#* Name of a btop++/bpytop/bashtop formatted ".theme" file, "Default" and "TTY" for builtin themes.
|
||||
#* Themes should be placed in "../share/btop/themes" relative to binary or "$HOME/.config/btop/themes"
|
||||
@@ -57,7 +57,7 @@ update_ms = 2000
|
||||
|
||||
#* Processes sorting, "pid" "program" "arguments" "threads" "user" "memory" "cpu lazy" "cpu direct",
|
||||
#* "cpu lazy" sorts top process over time (easier to follow), "cpu direct" updates top process directly.
|
||||
proc_sorting = "memory"
|
||||
proc_sorting = "cpu direct"
|
||||
|
||||
#* Reverse sorting order, True or False.
|
||||
proc_reversed = False
|
||||
@@ -115,6 +115,9 @@ cpu_bottom = False
|
||||
#* Shows the system uptime in the CPU box.
|
||||
show_uptime = True
|
||||
|
||||
#* Shows the CPU package current power consumption in watts. Requires running `make setcap` or `make setuid` or running with sudo.
|
||||
show_cpu_watts = True
|
||||
|
||||
#* Show cpu temperature.
|
||||
check_temp = True
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"allowDuplicates": false,
|
||||
"historyFile": "clipboard_history.json",
|
||||
"maxHistory": 20,
|
||||
"maxHistory": 40,
|
||||
"logFile": "clipse.log",
|
||||
"themeFile": "custom_theme.json",
|
||||
"tempDir": "tmp_files",
|
||||
|
||||
@@ -4,3 +4,9 @@ After updating you need to update hyprland packages to the latest version.
|
||||
```sh
|
||||
hyprpm update
|
||||
```
|
||||
|
||||
## Current plugins
|
||||
virtual-desktops: https://github.com/levnikmyskin/hyprland-virtual-desktops
|
||||
hyprexpo: https://github.com/hyprwm/hyprland-plugins
|
||||
DarkWindow: https://github.com/micha4w/Hypr-DarkWindow
|
||||
|
||||
|
||||
@@ -22,6 +22,14 @@ source = ~/.config/hypr/start-exec.conf
|
||||
source = ~/.config/hypr/windowrules.conf
|
||||
source = ~/.config/hypr/before-exit.conf
|
||||
source = ~/.config/hypr/keybinds.conf
|
||||
|
||||
# Plugins
|
||||
# hyprlang noerror true
|
||||
source = ~/.config/hypr/plugins/split-monitor-workspaces.conf
|
||||
|
||||
# hyprlang noerror false
|
||||
|
||||
|
||||
env = HYPRSHOT_DIR,/home/$USER/Pictures/Screenshots
|
||||
env = XDG_MENU_PREFIX,arch-
|
||||
|
||||
@@ -134,11 +142,8 @@ master {
|
||||
|
||||
gestures {
|
||||
# See https://wiki.hyprland.org/Configuring/Guestures/ for more
|
||||
|
||||
# hyprlang noerror true
|
||||
gesture = 3, right, dispatcher, prevdesk
|
||||
gesture = 3, left, dispatcher, nextdesk
|
||||
# hyprlang noerror false
|
||||
gesture = 3, horizontal, workspace
|
||||
gesture = 3, vertical, special, terminal
|
||||
}
|
||||
|
||||
cursor {
|
||||
@@ -149,22 +154,15 @@ misc {
|
||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||
disable_splash_rendering = 1
|
||||
disable_hyprland_logo = 1
|
||||
focus_on_activate = 0 # This breaks vdesks
|
||||
focus_on_activate = 1 # This breaks vdesks
|
||||
anr_missed_pings = 10
|
||||
}
|
||||
ecosystem {
|
||||
no_donation_nag = 1
|
||||
}
|
||||
# hyprlang noerror true
|
||||
|
||||
plugin {
|
||||
virtual-desktops {
|
||||
names = 1:Coding, 2:Internet, 3:3,4:4, 5:Social
|
||||
cycleworkspaces = 0
|
||||
rememberlayout = none
|
||||
notifyinit = 0
|
||||
verbose_logging = 0
|
||||
}
|
||||
}
|
||||
|
||||
plugin {
|
||||
hyprexpo {
|
||||
columns = 3
|
||||
@@ -180,7 +178,9 @@ plugin {
|
||||
}
|
||||
|
||||
# hyprlang noerror false
|
||||
|
||||
debug {
|
||||
disable_logs = false
|
||||
}
|
||||
|
||||
# Example per-device config
|
||||
# See https://wiki.hyprland.org/Configuring/Keywords/#per-device-input-configs for more
|
||||
|
||||
@@ -12,6 +12,8 @@ auth {
|
||||
# GENERAL
|
||||
general {
|
||||
hide_cursor = true
|
||||
screencopy_mode = 0
|
||||
immediate_render = false
|
||||
}
|
||||
|
||||
animation {
|
||||
@@ -21,26 +23,110 @@ animation {
|
||||
|
||||
# BACKGROUND
|
||||
background {
|
||||
path = $HOME/.config/lockpaper
|
||||
|
||||
path = screenshot
|
||||
blur_passes = 2
|
||||
#reload_time = 15
|
||||
#reload_cmd = echo $HOME/.config/lockpaper
|
||||
blur_passes = 0
|
||||
# blur_passes = 0
|
||||
crossfade_time = 1
|
||||
}
|
||||
# TIME
|
||||
|
||||
# AUTO BACKGROUND
|
||||
# AUTO BACKGROUND END
|
||||
|
||||
# Time-Hour
|
||||
label {
|
||||
text = $TIME
|
||||
color = rgb(255, 255, 255)
|
||||
font_size = 90
|
||||
font_family = $font
|
||||
position = 75, 0
|
||||
halign = left
|
||||
valign = top
|
||||
monitor =
|
||||
text = cmd[update:1000] echo "<span>$(date +"%I")</span>"
|
||||
color = rgba(255, 255, 255, 1)
|
||||
font_size = 125
|
||||
font_family = StretchPro
|
||||
position = -80, 290
|
||||
halign = center
|
||||
valign = center
|
||||
shadow_passes = 3
|
||||
shadow_size = 3
|
||||
shadow_color = rgba(0, 0, 0, 1)
|
||||
}
|
||||
|
||||
# Time-Minute
|
||||
label {
|
||||
monitor =
|
||||
text = cmd[update:1000] echo "<span>$(date +"%M")</span>"
|
||||
color = rgba(147, 196, 255, 1)
|
||||
font_size = 125
|
||||
font_family = StretchPro
|
||||
position = 0, 170
|
||||
halign = center
|
||||
valign = center
|
||||
shadow_passes = 3
|
||||
shadow_size = 3
|
||||
shadow_color = rgba(0, 0, 0,1)
|
||||
}
|
||||
|
||||
# Day-Month-Date
|
||||
label {
|
||||
monitor =
|
||||
text = cmd[update:1000] echo -e "$(date +"%d %B")"
|
||||
color = rgba(255, 255, 255, 1)
|
||||
font_size = 22
|
||||
font_family = Suisse Int'l Mono
|
||||
position = 20, 92
|
||||
halign = center
|
||||
valign = center
|
||||
shadow_passes = 3
|
||||
shadow_size = 5
|
||||
shadow_color = rgba(0, 0, 0, 1)
|
||||
}
|
||||
|
||||
# USER AVATAR
|
||||
image {
|
||||
monitor =
|
||||
path = $HOME/.face
|
||||
rounding = 25
|
||||
size = 200
|
||||
# border_color = rgb(0, 0, 0)
|
||||
border_size = 0
|
||||
position = 0, -100
|
||||
halign = center
|
||||
valign = center
|
||||
}
|
||||
|
||||
# INPUT FIELD
|
||||
input-field {
|
||||
monitor =
|
||||
size = 300, 60
|
||||
outline_thickness = 2
|
||||
dots_size = 0.2 # Scale of input-field height, 0.2 - 0.8
|
||||
dots_spacing = 0.2 # Scale of dots' absolute size, 0.0 - 1.0
|
||||
dots_center = true
|
||||
outer_color = rgba(255, 255, 255, 1)
|
||||
inner_color = rgba(0, 0, 0, 1)
|
||||
font_color = rgb(200, 200, 200)
|
||||
fade_on_empty = false
|
||||
font_family = SF Pro Display Bold
|
||||
placeholder_text = <i><span foreground="##ffffff99">Password...</span></i>
|
||||
hide_input = false
|
||||
position = 0, -290
|
||||
halign = center
|
||||
valign = center
|
||||
}
|
||||
|
||||
# CURRENT SONG
|
||||
label {
|
||||
monitor = eDP-1
|
||||
text = cmd[update:1000] echo "$(~/.config/hypr/scripts/songdetail.sh)"
|
||||
color = rgba(147, 196, 255, 1)
|
||||
font_size = 18
|
||||
font_family = JetBrains Mono Nerd, SF Pro Display Bold
|
||||
position = 0, 20
|
||||
halign = center
|
||||
valign = bottom
|
||||
}
|
||||
|
||||
# Battery
|
||||
label {
|
||||
monitor = eDP-1
|
||||
text = cmd[update:1000] /home/nathan/.config/hypr/scripts/battery.sh
|
||||
color = rgb(255, 255, 255)
|
||||
font_size = 20
|
||||
@@ -50,62 +136,15 @@ label {
|
||||
valign = bottom
|
||||
}
|
||||
|
||||
# DATE
|
||||
# label {
|
||||
# # monitor =
|
||||
# text = cmd[update:43200000] date +"%A, %d %B %Y"
|
||||
# color = rgb(255, 255, 255)
|
||||
# font_size = 25
|
||||
# font_family = $font
|
||||
# position = 30, -150
|
||||
# halign = left
|
||||
# valign = top
|
||||
# }
|
||||
shape {
|
||||
monitor =
|
||||
size = 500, 100%
|
||||
color = rgba(255, 255, 255, 0.18)
|
||||
rounding = 25
|
||||
# border_size = 4
|
||||
# border_color = rgba(255, 255, 255, 1.0)
|
||||
|
||||
position = -25, 0
|
||||
# Stats
|
||||
label {
|
||||
monitor = eDP-1
|
||||
text = cmd[update:15000] /home/nathan/.config/hypr/scripts/stats.sh
|
||||
color = rgb(255, 255, 255)
|
||||
font_size = 10
|
||||
font_family = Symbols Nerd Font Mono
|
||||
position = 10, 10
|
||||
halign = left
|
||||
valign = center
|
||||
}
|
||||
|
||||
# USER AVATAR
|
||||
image {
|
||||
# monitor =
|
||||
path = $HOME/.face
|
||||
rounding = 25
|
||||
size = 200
|
||||
# border_color = rgb(0, 0, 0)
|
||||
border_size = 0
|
||||
position = 150, 100
|
||||
halign = left
|
||||
valign = center
|
||||
}
|
||||
|
||||
# INPUT FIELD
|
||||
input-field {
|
||||
# monitor =
|
||||
size = 300, 60
|
||||
position = 100, -47
|
||||
outline_thickness = 4
|
||||
dots_size = 0.2
|
||||
dots_spacing = 0.2
|
||||
dots_center = true
|
||||
outer_color = rgb(0, 0, 0)
|
||||
inner_color = rgb(255, 255, 255)
|
||||
font_color = rgb(0, 0, 0)
|
||||
fade_on_empty = false
|
||||
placeholder_text = <span foreground="black"><i></i> Nathan</span>
|
||||
hide_input = false
|
||||
check_color = rgb(212, 130, 6)
|
||||
fail_color = rgb(255, 0, 0)
|
||||
fail_text = <i>$FAIL <b>($ATTEMPTS)</b></i>
|
||||
capslock_color = rgb(255, 0, 0)
|
||||
halign = left
|
||||
valign = center
|
||||
valign = bottom
|
||||
}
|
||||
@@ -4,28 +4,27 @@ $fileManager = dolphin
|
||||
$menu = pgrep -x tofi-drun && pkill -x tofi-drun || tofi-drun --drun-launch=true > ~/.logs/tofi-drun.log 2>&1 &
|
||||
$clipboard = /home/nathan/.local/bin/clipse
|
||||
$StartWallpaperTimer = systemctl --user start wallpaper.timer && WallRizz -r -n -d ~/.config/backgrounds
|
||||
|
||||
|
||||
|
||||
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||
$mainMod = SUPER
|
||||
|
||||
# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more
|
||||
|
||||
bind = CTRL ALT, T, exec, $terminal
|
||||
bind = $mainMod, Q, killactive,
|
||||
bind = $mainMod, F, togglefloating,
|
||||
bind = $mainMod, space, exec, $menu
|
||||
bind = ALT, SPACE, exec, ~/.config/hypr/scripts/search-windows.sh
|
||||
bind = $mainMod, L, exec, hyprlock
|
||||
bind = $mainMod, L, exec, ~/.config/hypr/scripts/lock.sh
|
||||
bind = $mainMod, H, exec, alacritty --class float -e ~/.config/hypr/scripts/help.py
|
||||
bind = CTRL ALT, DELETE, exec, hyprpanel t powermenu
|
||||
|
||||
#bind = $mainMod, V, exec, [float] alacritty --class clipse -e /home/nathan/.local/bin/clipse
|
||||
bind = $mainMod, V, exec, [float] kitty --class float-80 -e $clipboard
|
||||
|
||||
|
||||
|
||||
# bind = $mainMod, P, pseudo, # dwindle
|
||||
bind = $mainMod, J, togglesplit,
|
||||
# Layout
|
||||
bind = $mainMod, J, togglesplit, # Split direction
|
||||
bind = $mainMod, code:35, togglesplit, # Split direction
|
||||
bind = $mainMod SHIFT, J,swapsplit # Swap master and secondary in dwindle
|
||||
|
||||
# Move focus with mainMod + arrow keys
|
||||
bind = $mainMod, left, movefocus, l
|
||||
@@ -33,59 +32,22 @@ bind = $mainMod, right, movefocus, r
|
||||
bind = $mainMod, up, movefocus, u
|
||||
bind = $mainMod, down, movefocus, d
|
||||
|
||||
# Switch workspaces with mainMod + [0-9]
|
||||
# bind = $mainMod ALT, 1, workspace, 1
|
||||
# bind = $mainMod ALT, 2, workspace, 2
|
||||
# bind = $mainMod ALT, 3, workspace, 3
|
||||
# bind = $mainMod ALT, 4, workspace, 4
|
||||
# bind = $mainMod ALT, 5, workspace, 5
|
||||
# bind = $mainMod ALT, 6, workspace, 6
|
||||
# bind = $mainMod ALT, 7, workspace, 7
|
||||
# bind = $mainMod ALT, 8, workspace, 8
|
||||
# bind = $mainMod ALT, 9, workspace, 9
|
||||
# bind = $mainMod ALT, 0, workspace, 10
|
||||
|
||||
# hyprlang noerror true
|
||||
bind = $mainMod, 1, vdesk, 1
|
||||
bind = $mainMod, 2, vdesk, 2
|
||||
bind = $mainMod, 3, vdesk, 3
|
||||
bind = $mainMod, 4, vdesk, 4
|
||||
bind = $mainMod, 5, vdesk, 5
|
||||
bind = $mainMod, 6, vdesk, 6
|
||||
bind = $mainMod, 7, vdesk, 7
|
||||
bind = $mainMod, 8, vdesk, 8
|
||||
bind = $mainMod, 9, vdesk, 9
|
||||
bind = $mainMod, 0, vdesk, 10
|
||||
|
||||
# Move active window to a workspace with mainMod + SHIFT + [0-9]
|
||||
bind = $mainMod SHIFT, 1, movetodesk, 1
|
||||
bind = $mainMod SHIFT, 2, movetodesk, 2
|
||||
bind = $mainMod SHIFT, 3, movetodesk, 3
|
||||
bind = $mainMod SHIFT, 4, movetodesk, 4
|
||||
bind = $mainMod SHIFT, 5, movetodesk, 5
|
||||
bind = $mainMod SHIFT, 6, movetodesk, 6
|
||||
bind = $mainMod SHIFT, 7, movetodesk, 7
|
||||
bind = $mainMod SHIFT, 8, movetodesk, 8
|
||||
bind = $mainMod SHIFT, 9, movetodesk, 9
|
||||
bind = $mainMod SHIFT, 0, movetodesk, 10
|
||||
|
||||
# Example special workspace (scratchpad)
|
||||
# Dedicated special workspace for terminal
|
||||
bind = $mainMod, S, togglespecialworkspace, terminal
|
||||
bind = $mainMod CTRL, S, movetoworkspace, special:terminal
|
||||
bind = CTRL ALT, TAB, togglespecialworkspace, terminal
|
||||
|
||||
# Screenshots
|
||||
bind = $mainMod SHIFT, S, exec, hyprshot -m region
|
||||
bind = $mainMod CTRL SHIFT, S, exec, hyprshot -m window -m active
|
||||
|
||||
# hyprlang noerror true
|
||||
|
||||
|
||||
# Used to use overview:toggle, but that resises the windows
|
||||
# bind = $mainMod, TAB, overview:toggle
|
||||
# bind = CTRL ALT, TAB, overview:toggle
|
||||
|
||||
# hyprlang noerror true
|
||||
|
||||
bind = $mainMod, TAB, hyprexpo:expo, toggle
|
||||
bind = ALT, TAB, lastdesk
|
||||
bind = CTRL ALT, TAB, togglespecialworkspace, terminal
|
||||
|
||||
# hyprlang noerror false
|
||||
|
||||
@@ -105,7 +67,7 @@ bindl=, XF86AudioNext, exec, playerctl next
|
||||
bindl=, XF86AudioPrev, exec, playerctl previous
|
||||
|
||||
# Other FN keys
|
||||
bindl= $mainMod CTRL, XF86TouchpadToggle, exec, hyprctl notify -1 2000 -1 "TODO Touchpad Toggle"
|
||||
bind= $mainMod CTRL, XF86TouchpadToggle, exec, hyprctl notify -1 2000 -1 "TODO Touchpad Toggle"
|
||||
bind = $mainMod, P, exec, hyprctl notify -1 2000 -1 "TODO Screen Settings"
|
||||
bindl = , Print, exec, hyprshot -m output -m active
|
||||
bind = $mainMod, Print, exec, hyprshot -m window -m active
|
||||
@@ -113,6 +75,7 @@ bind = $mainMod CTRL, Print, exec, hyprshot -m region
|
||||
|
||||
# Move/resize windows with mainMod + LMB/RMB and dragging
|
||||
bindm = $mainMod, mouse:272, movewindow
|
||||
bindm = $mainMod SHIFT, mouse:272, resizewindow
|
||||
bindm = $mainMod, mouse:273, resizewindow
|
||||
|
||||
# Mouse wheel tilt
|
||||
@@ -140,13 +103,23 @@ submap = capsmode
|
||||
# Bindings for submap
|
||||
|
||||
bind = , 1, exec, hyprctl notify 5 2000 0 "Opening Brave Browser"
|
||||
bind = , 1, exec, brave --proxy-pac-url="https://pac.cn01.woodburn.au/proxy.pac" --enable-features=UseOzonePlatform --ozone-platform=wayland --use-gl=angle --ignore-gpu-blocklist --enable-features=VaapiVideoEncoder,VaapiVideoDecoder,CanvasOopRasterization,VaapiIgnoreDriverChecks,VaapiVideoDecodeLinuxGL,AcceleratedVideoEncoder,Vulkan,DefaultANGLEVulkan,VulkanFromANGLE --disable-gpu-memory-buffer-video-frames
|
||||
bind = , 1, exec, brave --proxy-pac-url="https://pac.cn01.woodburn.au/proxy.pac" --enable-features=UseOzonePlatform --ozone-platform=wayland --use-gl=angle --ignore-gpu-blocklist --enable-features=VaapiVideoEncoder,VaapiVideoDecoder,CanvasOopRasterization,VaapiIgnoreDriverChecks,VaapiVideoDecodeLinuxGL,AcceleratedVideoEncoder --disable-gpu-memory-buffer-video-frames --disable-features=WaylandWpColorManagerV1
|
||||
bind = , 1, submap, reset
|
||||
|
||||
bind = , 2, exec, hyprpanel -q
|
||||
bind = , 2, exec, hyprpanel
|
||||
bind = , 2, submap, reset
|
||||
|
||||
bind = CTRL, 3, movetoworkspace, special:alternate
|
||||
bind = CTRL, 3, submap, reset
|
||||
|
||||
bind = , 3, togglespecialworkspace, alternate
|
||||
bind = , 3, submap, reset
|
||||
|
||||
|
||||
bind = , T, exec, hyprctl notify 5 2000 0 "Select text to copy to clipboard..."
|
||||
bind = , T, exec, ~/.config/OCR4Linux/OCR4Linux.sh --lang eng -r
|
||||
bind = , T, submap, reset
|
||||
|
||||
# Disable errors for this plugin
|
||||
# hyprlang noerror true
|
||||
|
||||
31
.config/hypr/plugins/split-monitor-workspaces.conf
Normal file
31
.config/hypr/plugins/split-monitor-workspaces.conf
Normal file
@@ -0,0 +1,31 @@
|
||||
# https://github.com/Duckonaut/split-monitor-workspaces
|
||||
|
||||
bind = $mainMod, 1, split-workspace, 1
|
||||
bind = $mainMod, 2, split-workspace, 2
|
||||
bind = $mainMod, 3, split-workspace, 3
|
||||
bind = $mainMod, 4, split-workspace, 4
|
||||
bind = $mainMod, 5, split-workspace, 5
|
||||
bind = $mainMod, 6, split-workspace, 6
|
||||
bind = $mainMod, 7, split-workspace, 7
|
||||
bind = $mainMod, 8, split-workspace, 8
|
||||
bind = $mainMod, 9, split-workspace, 9
|
||||
bind = $mainMod, 0, split-workspace, 10
|
||||
|
||||
# Move active window to a workspace with mainMod + SHIFT + [0-9]
|
||||
bind = $mainMod SHIFT, 1, split-movetoworkspace, 1
|
||||
bind = $mainMod SHIFT, 2, split-movetoworkspace, 2
|
||||
bind = $mainMod SHIFT, 3, split-movetoworkspace, 3
|
||||
bind = $mainMod SHIFT, 4, split-movetoworkspace, 4
|
||||
bind = $mainMod SHIFT, 5, split-movetoworkspace, 5
|
||||
bind = $mainMod SHIFT, 6, split-movetoworkspace, 6
|
||||
bind = $mainMod SHIFT, 7, split-movetoworkspace, 7
|
||||
bind = $mainMod SHIFT, 8, split-movetoworkspace, 8
|
||||
bind = $mainMod SHIFT, 9, split-movetoworkspace, 9
|
||||
bind = $mainMod SHIFT, 0, split-movetoworkspace, 10
|
||||
|
||||
bind = ALT, TAB, lastdesk
|
||||
|
||||
# Window rules for sticky apps
|
||||
windowrule = workspace 5, class:vesktop
|
||||
windowrule = workspace 5, class:org.telegram.desktop
|
||||
windowrule = workspace 5, class:Slack
|
||||
44
.config/hypr/plugins/virtual-desktops.conf
Normal file
44
.config/hypr/plugins/virtual-desktops.conf
Normal file
@@ -0,0 +1,44 @@
|
||||
# https://github.com/levnikmyskin/hyprland-virtual-desktops
|
||||
|
||||
bind = $mainMod, 1, vdesk, 1
|
||||
bind = $mainMod, 2, vdesk, 2
|
||||
bind = $mainMod, 3, vdesk, 3
|
||||
bind = $mainMod, 4, vdesk, 4
|
||||
bind = $mainMod, 5, vdesk, 5
|
||||
bind = $mainMod, 6, vdesk, 6
|
||||
bind = $mainMod, 7, vdesk, 7
|
||||
bind = $mainMod, 8, vdesk, 8
|
||||
bind = $mainMod, 9, vdesk, 9
|
||||
bind = $mainMod, 0, vdesk, 10
|
||||
|
||||
# Move active window to a workspace with mainMod + SHIFT + [0-9]
|
||||
bind = $mainMod SHIFT, 1, movetodesk, 1
|
||||
bind = $mainMod SHIFT, 2, movetodesk, 2
|
||||
bind = $mainMod SHIFT, 3, movetodesk, 3
|
||||
bind = $mainMod SHIFT, 4, movetodesk, 4
|
||||
bind = $mainMod SHIFT, 5, movetodesk, 5
|
||||
bind = $mainMod SHIFT, 6, movetodesk, 6
|
||||
bind = $mainMod SHIFT, 7, movetodesk, 7
|
||||
bind = $mainMod SHIFT, 8, movetodesk, 8
|
||||
bind = $mainMod SHIFT, 9, movetodesk, 9
|
||||
bind = $mainMod SHIFT, 0, movetodesk, 10
|
||||
|
||||
bind = ALT, TAB, lastdesk
|
||||
|
||||
stickyrule = class:discord,5
|
||||
stickyrule = class:vesktop,5
|
||||
stickyrule = class:org.telegram.desktop,5
|
||||
stickyrule = class:Slack,5
|
||||
|
||||
gesture = 3, right, dispatcher, prevdesk
|
||||
gesture = 3, left, dispatcher, nextdesk
|
||||
|
||||
plugin {
|
||||
virtual-desktops {
|
||||
names = 1:Coding, 2:Internet, 3:3,4:4, 5:Social
|
||||
cycleworkspaces = 0
|
||||
rememberlayout = none
|
||||
notifyinit = 0
|
||||
verbose_logging = 0
|
||||
}
|
||||
}
|
||||
@@ -11,10 +11,12 @@ nextcloud &
|
||||
# discord --start-minimized & Using vesktop now
|
||||
|
||||
sleep 2
|
||||
vesktop --start-minimized &
|
||||
vesktop --ozone-platform-hint=auto --start-minimized &
|
||||
kdeconnect-indicator &
|
||||
WallRizz -r -n -d ~/.config/backgrounds
|
||||
|
||||
walker --gapplication-service &
|
||||
|
||||
|
||||
# Misc
|
||||
/home/nathan/scripts/mute.sh
|
||||
|
||||
57
.config/hypr/scripts/lock.sh
Executable file
57
.config/hypr/scripts/lock.sh
Executable file
@@ -0,0 +1,57 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
echo "Preparing hyprlock configuration..."
|
||||
# Path to hyprlock configuration file
|
||||
CONF="$HOME/.config/hypr/hyprlock.conf"
|
||||
# Get the list of outputs
|
||||
mapfile -t outputs < <(hyprctl -j monitors | jq -r '.[].name')
|
||||
|
||||
# Generate the background blocks for each output
|
||||
block=""
|
||||
for output in "${outputs[@]}"; do
|
||||
block+=$'background {\n'
|
||||
block+=$" monitor = ${output}\n"
|
||||
block+=$" path = screenshot\n"
|
||||
block+=$" reload_time = 0\n"
|
||||
block+=$" reload_cmd = echo \"/tmp/${output}-lockscreen.png\"\n"
|
||||
block+=$" crossfade_time = 1\n"
|
||||
block+=$'}\n\n'
|
||||
done
|
||||
# Insert the generated blocks into the configuration file
|
||||
awk -v content="$block" '
|
||||
/^# AUTO BACKGROUND$/ { print; print content; inside=1; next }
|
||||
inside && /^# AUTO BACKGROUND END$/ { print; inside=0; next }
|
||||
inside { next }
|
||||
{ print }
|
||||
' "$CONF" > "${CONF}.tmp" && mv "${CONF}.tmp" "$CONF"
|
||||
|
||||
echo "Starting hyprlock..."
|
||||
/home/nathan/Git/hyprlock/build/hyprlock &
|
||||
|
||||
echo "Taking screenshots for lock screen..."
|
||||
# Take a screenshot of each output before locking (!THIS IS SLOW!)
|
||||
for output in "${outputs[@]}"; do
|
||||
# grim -o "$output" "/tmp/${output}-lockscreen.png" &
|
||||
$HOME/.config/hypr/scripts/spots.sh -s 8 <(grim -o "$output" -) "/tmp/${output}-lockscreen.png" &
|
||||
done
|
||||
|
||||
echo "Waiting for screenshots to complete..."
|
||||
# Wait for all image processing to complete
|
||||
while pgrep -x spots.sh >/dev/null; do
|
||||
sleep 0.1
|
||||
done
|
||||
# Notify hyprlock to reload backgrounds
|
||||
echo "Reloading hyprlock backgrounds..."
|
||||
pkill -USR2 hyprlock
|
||||
|
||||
echo "Waiting for hyprlock to exit..."
|
||||
wait
|
||||
|
||||
echo "Hyprlock exited. Cleaning up..."
|
||||
# Cleanup: Restore hyprlock.conf to original state
|
||||
sed -i '/^# AUTO BACKGROUND$/,/^# AUTO BACKGROUND END$/{//!d}' "$CONF"
|
||||
|
||||
# Remove the screenshots
|
||||
for output in "${outputs[@]}"; do
|
||||
rm "/tmp/${output}-lockscreen.png"
|
||||
done
|
||||
5
.config/hypr/scripts/songdetail.sh
Executable file
5
.config/hypr/scripts/songdetail.sh
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
song_info=$(playerctl metadata --format '{{title}} {{artist}}')
|
||||
|
||||
echo "$song_info"
|
||||
380
.config/hypr/scripts/spots.sh
Executable file
380
.config/hypr/scripts/spots.sh
Executable file
@@ -0,0 +1,380 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Developed by Fred Weinhaus 8/4/2011 .......... 5/28/2015
|
||||
#
|
||||
# ------------------------------------------------------------------------------
|
||||
#
|
||||
# Licensing:
|
||||
#
|
||||
# Copyright © Fred Weinhaus
|
||||
#
|
||||
# My scripts are available free of charge for non-commercial use, ONLY.
|
||||
#
|
||||
# For use of my scripts in commercial (for-profit) environments or
|
||||
# non-free applications, please contact me (Fred Weinhaus) for
|
||||
# licensing arrangements. My email address is fmw at alink dot net.
|
||||
#
|
||||
# If you: 1) redistribute, 2) incorporate any of these scripts into other
|
||||
# free applications or 3) reprogram them in another scripting language,
|
||||
# then you must contact me for permission, especially if the result might
|
||||
# be used in a commercial or for-profit environment.
|
||||
#
|
||||
# My scripts are also subject, in a subordinate manner, to the ImageMagick
|
||||
# license, which can be found at: http://www.imagemagick.org/script/license.php
|
||||
#
|
||||
# ------------------------------------------------------------------------------
|
||||
#
|
||||
####
|
||||
#
|
||||
# USAGE: spots [-s size] [-t type] [-p pad] [-b bgcolor] [-e edge] [-E ecolor] [-B brightness] [-C Contrast] infile [spotfile] outfile
|
||||
# USAGE: spots [-help]
|
||||
#
|
||||
# OPTIONS:
|
||||
#
|
||||
# -s size spot size expressed as WxH in pixels; default=5x5
|
||||
# -t type type of spot shape; choices are: circle (or c),
|
||||
# square (or s), or diamond (or d); default=circle
|
||||
# -p pad padding or border around spot cell in pixels on
|
||||
# each side; integer>=0; default=1
|
||||
# -b bgcolor background color to apply to image where spot
|
||||
# does not cover; any valid IM color; default=black
|
||||
# -e edge edge thickness accent around spot shape;
|
||||
# integer>=0; default=0
|
||||
# -E ecolor color of accent edge around spot shape;
|
||||
# any valid IM color; default=gray
|
||||
# -B brightness percent change in brightness of spots;
|
||||
# integer; default=0
|
||||
# -C contrast percent change in contrast of spots;
|
||||
# integer; default=0
|
||||
#
|
||||
#
|
||||
###
|
||||
#
|
||||
# NAME: SPOTS
|
||||
#
|
||||
# PURPOSE: Converts the image into a series of uniform-colored spots.
|
||||
#
|
||||
# DESCRIPTION: SPOTS converts the image into a series of uniform-colored
|
||||
# spots. The shape of spots allowed are: circle (ellipse), square (rectangle)
|
||||
# or diamond. The spot size may be adjusted. A colored edge may also be
|
||||
# placed around each spot. An optional spotfile may be provided to define
|
||||
# some other shape than those built-in.
|
||||
#
|
||||
#
|
||||
# OPTIONS:
|
||||
#
|
||||
# -s size ... SIZE is the WxH dimensions of the spot cell. Values are a
|
||||
# pair of positive integers separated by an x. The default=5x5. If only
|
||||
# one value is provided, it will be used for both. This parameter is
|
||||
# ignored if a spotfile is provided.
|
||||
#
|
||||
# -t type ... TYPE is the type of spot shape. The choices are: circle (or c),
|
||||
# square (or s), diamond (or d). These may be asymmetric as ellipses or
|
||||
# rectangles as controlled by the size parameters. This parameter is
|
||||
# ignored if a spotfile is provided.
|
||||
#
|
||||
# -p pad ... PAD is the border around the spot cell. Values are integers>=0.
|
||||
# The default=0.
|
||||
#
|
||||
# -b bgcolor ... BGCOLOR is the color to apply to the image between the spots.
|
||||
# Any valid IM color is allowed. The default=black.
|
||||
#
|
||||
# -e edge ... EDGE is the thickness of the optional edge hightlight around
|
||||
# the spot shape. Values are integers>=0. The default=0.
|
||||
#
|
||||
# -E ecolor ... ECOLOR is the color of the edge highlight. Any valid IM color
|
||||
# is allowed. The default=gray.
|
||||
#
|
||||
# -B brightness ... BRIGHTNESS is the percent change in brightness of the
|
||||
# spot colors. Values are integers. The default=0
|
||||
#
|
||||
# -C contrast ... CONTRAST is the percent change in contrast of the
|
||||
# spot colors. Values are integers. The default=0
|
||||
#
|
||||
# The spotfile must be a binary mask with white for the shape and black
|
||||
# for the background and no alpha channel.
|
||||
#
|
||||
# REQUIREMENTS: IM 6.3.6-1 or higher due to the use of
|
||||
# -define distort:viewport=WxH+X+Y with -distort SRT.
|
||||
#
|
||||
# CAVEAT: No guarantee that this script will work on all platforms,
|
||||
# nor that trapping of inconsistent parameters is complete and
|
||||
# foolproof. Use At Your Own Risk.
|
||||
#
|
||||
######
|
||||
#
|
||||
|
||||
# set default values
|
||||
size="5x5" # spot WxH
|
||||
type="circle" # circle, square, diamond
|
||||
pad=1 # border padding
|
||||
edge=0 # edge width
|
||||
ecolor="gray" # edge color
|
||||
bgcolor="black" # background color
|
||||
bri=0 # brightness
|
||||
con=0 # contrast
|
||||
|
||||
# set directory for temporary files
|
||||
dir="." # suggestions are dir="." or dir="/tmp"
|
||||
|
||||
# set up functions to report Usage and Usage with Description
|
||||
PROGNAME=`type $0 | awk '{print $3}'` # search for executable on path
|
||||
PROGDIR=`dirname $PROGNAME` # extract directory of program
|
||||
PROGNAME=`basename $PROGNAME` # base name of program
|
||||
usage1()
|
||||
{
|
||||
echo >&2 ""
|
||||
echo >&2 "$PROGNAME:" "$@"
|
||||
sed >&2 -e '1,/^####/d; /^###/g; /^#/!q; s/^#//; s/^ //; 4,$p' "$PROGDIR/$PROGNAME"
|
||||
}
|
||||
usage2()
|
||||
{
|
||||
echo >&2 ""
|
||||
echo >&2 "$PROGNAME:" "$@"
|
||||
sed >&2 -e '1,/^####/d; /^######/g; /^#/!q; s/^#*//; s/^ //; 4,$p' "$PROGDIR/$PROGNAME"
|
||||
}
|
||||
|
||||
|
||||
# function to report error messages
|
||||
errMsg()
|
||||
{
|
||||
echo ""
|
||||
echo $1
|
||||
echo ""
|
||||
usage1
|
||||
exit 1
|
||||
}
|
||||
|
||||
|
||||
# function to test for minus at start of value of second part of option 1 or 2
|
||||
checkMinus()
|
||||
{
|
||||
test=`echo "$1" | grep -c '^-.*$'` # returns 1 if match; 0 otherwise
|
||||
[ $test -eq 1 ] && errMsg "$errorMsg"
|
||||
}
|
||||
|
||||
# test for correct number of arguments and get values
|
||||
if [ $# -eq 0 ]
|
||||
then
|
||||
# help information
|
||||
echo ""
|
||||
usage2
|
||||
exit 0
|
||||
elif [ $# -gt 19 ]
|
||||
then
|
||||
errMsg "--- TOO MANY ARGUMENTS WERE PROVIDED ---"
|
||||
else
|
||||
while [ $# -gt 0 ]
|
||||
do
|
||||
# get parameter values
|
||||
case "$1" in
|
||||
-help) # help information
|
||||
echo ""
|
||||
usage2
|
||||
exit 0
|
||||
;;
|
||||
-s) # get size
|
||||
shift # to get the next parameter
|
||||
# test if parameter starts with minus sign
|
||||
errorMsg="--- INVALID SIZE SPECIFICATION ---"
|
||||
checkMinus "$1"
|
||||
size=`expr "$1" : '\([0-9]*[x]*[0-9]*\)'`
|
||||
[ "$size" = "" ] && errMsg "--- SIZE=$size MUST BE A PAIR OF POSITIVE INTEGERS (with no sign) SEPARATED BY AN x ---"
|
||||
;;
|
||||
-t) # type
|
||||
shift # to get the next parameter
|
||||
# test if parameter starts with minus sign
|
||||
errorMsg="--- INVALID TYPE SPECIFICATION ---"
|
||||
checkMinus "$1"
|
||||
# test mode values
|
||||
type="$1"
|
||||
type=`echo "$type" | tr "[:upper:]" "[:lower:]"`
|
||||
case "$type" in
|
||||
circle|c) type="circle" ;;
|
||||
square|s) type="square" ;;
|
||||
diamond|d) type="diamond" ;;
|
||||
*) errMsg "--- TYPE=$type IS AN INVALID VALUE ---"
|
||||
esac
|
||||
;;
|
||||
-p) # get pad
|
||||
shift # to get the next parameter
|
||||
# test if parameter starts with minus sign
|
||||
errorMsg="--- INVALID PAD SPECIFICATION ---"
|
||||
checkMinus "$1"
|
||||
pad=`expr "$1" : '\([0-9]*\)'`
|
||||
[ "$pad" = "" ] && errMsg "--- PAD=$pad MUST BE A NON-NEGATIVE INTEGER (with no sign) ---"
|
||||
;;
|
||||
-b) # get bgcolor
|
||||
shift # to get the next parameter
|
||||
# test if parameter starts with minus sign
|
||||
errorMsg="--- INVALID BGCOLOR SPECIFICATION ---"
|
||||
checkMinus "$1"
|
||||
bgcolor="$1"
|
||||
;;
|
||||
-e) # get edge
|
||||
shift # to get the next parameter
|
||||
# test if parameter starts with minus sign
|
||||
errorMsg="--- INVALID EDGE SPECIFICATION ---"
|
||||
checkMinus "$1"
|
||||
edge=`expr "$1" : '\([0-9]*\)'`
|
||||
[ "$edge" = "" ] && errMsg "--- EDGE=$edge MUST BE A NON-NEGATIVE INTEGER (with no sign) ---"
|
||||
;;
|
||||
-E) # get ecolor
|
||||
shift # to get the next parameter
|
||||
# test if parameter starts with minus sign
|
||||
errorMsg="--- INVALID ECOLOR SPECIFICATION ---"
|
||||
checkMinus "$1"
|
||||
ecolor="$1"
|
||||
;;
|
||||
-B) # get brightness
|
||||
shift # to get the next parameter
|
||||
# test if parameter starts with minus sign
|
||||
errorMsg="--- INVALID BRIGHTNESS SPECIFICATION ---"
|
||||
#checkMinus "$1"
|
||||
bri=`expr "$1" : '\([-0-9]*\)'`
|
||||
[ "$bri" = "" ] && errMsg "--- BRIGHTNESS=$bri MUST BE AN INTEGER (with no sign) ---"
|
||||
;;
|
||||
-C) # get contrast
|
||||
shift # to get the next parameter
|
||||
# test if parameter starts with minus sign
|
||||
errorMsg="--- INVALID CONTRAST SPECIFICATION ---"
|
||||
#checkMinus "$1"
|
||||
con=`expr "$1" : '\([-0-9]*\)'`
|
||||
[ "$con" = "" ] && errMsg "--- CONTRAST=$con MUST BE AN INTEGER (with no sign) ---"
|
||||
;;
|
||||
-) # STDIN and end of arguments
|
||||
break
|
||||
;;
|
||||
-*) # any other - argument
|
||||
errMsg "--- UNKNOWN OPTION ---"
|
||||
;;
|
||||
*) # end of arguments
|
||||
break
|
||||
;;
|
||||
esac
|
||||
shift # next option
|
||||
done
|
||||
#
|
||||
# get infile and outfile and spotfile
|
||||
if [ $# -eq 3 ]; then
|
||||
infile="$1"
|
||||
spotfile="$2"
|
||||
outfile="$3"
|
||||
elif [ $# -eq 2 ]; then
|
||||
infile="$1"
|
||||
outfile="$2"
|
||||
else
|
||||
errMsg "--- INCONSISTENT NUMBER OF IMAGES PROVIDED ---"
|
||||
fi
|
||||
fi
|
||||
|
||||
# test that infile provided
|
||||
[ "$infile" = "" ] && errMsg "NO INPUT FILE SPECIFIED"
|
||||
|
||||
# test that outfile provided
|
||||
[ "$outfile" = "" ] && errMsg "NO OUTPUT FILE SPECIFIED"
|
||||
|
||||
# create temp files
|
||||
tmpA1="$dir/spots_1_$$.mpc"
|
||||
tmpB1="$dir/spots_1_$$.cache"
|
||||
tmpA2="$dir/spots_2_$$.mpc"
|
||||
tmpB2="$dir/spots_2_$$.cache"
|
||||
trap "rm -f $tmpA1 $tmpB1 $tmpA2 $tmpB2;" 0
|
||||
trap "rm -f $tmpA1 $tmpB1 $tmpA2 $tmpB2; exit 1" 1 2 3 15
|
||||
trap "rm -f $tmpA1 $tmpB1 $tmpA2 $tmpB2; exit 1" ERR
|
||||
|
||||
# setup brightness contrast
|
||||
if [ "$bri" = "0" -a "$con" = "0" ]; then
|
||||
bricon=""
|
||||
else
|
||||
bricon="-brightness-contrast $bri,$con"
|
||||
fi
|
||||
|
||||
# test input image
|
||||
magick -quiet "$infile" $bricon -clamp +repage "$tmpA1" ||
|
||||
errMsg "--- FILE $infile DOES NOT EXIST OR IS NOT AN ORDINARY FILE, NOT READABLE OR HAS ZERO SIZE ---"
|
||||
|
||||
# test spot file if exists
|
||||
if [ "$spotfile" != "" ]; then
|
||||
magick -quiet "$spotfile" -alpha off +repage "$tmpA2" ||
|
||||
errMsg "--- FILE $spotfile DOES NOT EXIST OR IS NOT AN ORDINARY FILE, NOT READABLE OR HAS ZERO SIZE ---"
|
||||
fi
|
||||
|
||||
# get image width, height and aspect
|
||||
ww=`magick $tmpA1 -ping -format "%w" info:`
|
||||
hh=`magick $tmpA1 -ping -format "%h" info:`
|
||||
|
||||
# get size of spot and center of spot and last pixel of spot and pad size
|
||||
if [ "$spotfile" = "" ]; then
|
||||
sw=`echo $size | cut -dx -f1`
|
||||
sh=`echo $size | cut -dx -f2`
|
||||
scx=`magick xc: -format "%[fx:($sw-1)/2]" info:`
|
||||
scy=`magick xc: -format "%[fx:($sh-1)/2]" info:`
|
||||
lx=$((sw-1))
|
||||
ly=$((sh-1))
|
||||
|
||||
# get pad size
|
||||
pw=$((sw+2*pad))
|
||||
ph=$((sh+2*pad))
|
||||
|
||||
else
|
||||
pw=`magick $tmpA2 -ping -format "%w" info:`
|
||||
ph=`magick $tmpA2 -ping -format "%h" info:`
|
||||
fi
|
||||
|
||||
|
||||
if [ "$spotfile" = "" ]; then
|
||||
if [ "$pad" = "0" ]; then
|
||||
padding=""
|
||||
else
|
||||
padding="-bordercolor black -border $pad"
|
||||
fi
|
||||
|
||||
# create spot template
|
||||
if [ "$type" = "circle" ]; then
|
||||
magick -size ${sw}x${sh} xc:black \
|
||||
+antialias -fill white -draw "ellipse $scx,$scy $scx,$scy 0,360" -alpha off \
|
||||
$padding \
|
||||
$tmpA2
|
||||
|
||||
elif [ "$type" = "square" ]; then
|
||||
magick -size ${sw}x${sh} xc:black \
|
||||
+antialias -fill white -draw "rectangle 0,0 $lx,$ly" -alpha off \
|
||||
$padding \
|
||||
$tmpA2
|
||||
|
||||
elif [ "$type" = "diamond" ]; then
|
||||
magick -size ${sw}x${sh} xc:black \
|
||||
+antialias -fill white -draw "polygon $scx,0 $lx,$scy $scx,$ly 0,$scy" -alpha off \
|
||||
$padding \
|
||||
$tmpA2
|
||||
fi
|
||||
fi
|
||||
|
||||
# compute xmin and ymin and virtual canvas size
|
||||
xmin=`magick xc: -format "%[fx:ceil($ww/$pw)]" info:`
|
||||
ymin=`magick xc: -format "%[fx:ceil($hh/$ph)]" info:`
|
||||
www=`magick xc: -format "%[fx:$xmin*$pw]" info:`
|
||||
hhh=`magick xc: -format "%[fx:$ymin*$ph]" info:`
|
||||
|
||||
|
||||
# process image
|
||||
if [ "$edge" = "0" ]; then
|
||||
magick \( $tmpA1 -define distort:viewport=${www}x${hhh}+0+0 -virtual-pixel mirror -distort SRT 0 \
|
||||
-scale ${xmin}x${ymin}! -scale ${www}x${hhh}! -crop ${ww}x${hh}+0+0 +repage \) \
|
||||
\( $tmpA2 -write mpr:tile +delete -size ${ww}x${hh}! tile:mpr:tile \) \
|
||||
-alpha off -compose copy_opacity -composite -compose over \
|
||||
-background $bgcolor -flatten \
|
||||
"$outfile"
|
||||
else
|
||||
magick \( $tmpA1 -define distort:viewport=${www}x${hhh}+0 -virtual-pixel mirror -distort SRT 0 \
|
||||
-scale ${xmin}x${ymin}! -scale ${www}x${hhh}! -crop ${ww}x${hh}+0+0 +repage \) \
|
||||
\( $tmpA2 -write mpr:tile +delete -size ${ww}x${hh}! tile:mpr:tile \) \
|
||||
\( -clone 1 -threshold 0 -edge $edge -clamp -fill $ecolor -opaque white -transparent black \) \
|
||||
\( -clone 0 -clone 1 -alpha off -compose copy_opacity -composite -compose over \
|
||||
-background $bgcolor -flatten \) \
|
||||
-delete 0,1 +swap -compose over -composite \
|
||||
"$outfile"
|
||||
fi
|
||||
|
||||
exit 0
|
||||
103
.config/hypr/scripts/stats.sh
Executable file
103
.config/hypr/scripts/stats.sh
Executable file
@@ -0,0 +1,103 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Get system statistics
|
||||
CPU_USAGE=$(top -bn1 | grep "Cpu(s)" | awk '{print 100 - $8}' | cut -d. -f1)
|
||||
MEMORY_USAGE=$(free -m | awk 'NR==2{printf "%.0f", $3*100/$2 }')
|
||||
|
||||
CPU_TEMP=""
|
||||
# Get temp info (CPU temp)
|
||||
if [ -r /sys/class/thermal/thermal_zone0/temp ]; then
|
||||
CPU_TEMP_RAW=$(cat /sys/class/thermal/thermal_zone0/temp)
|
||||
CPU_TEMP_C=$((CPU_TEMP_RAW / 1000))
|
||||
CPU_TEMP=" ${CPU_TEMP_C}°C"
|
||||
fi
|
||||
|
||||
|
||||
echo " ${CPU_USAGE}%${CPU_TEMP} ${MEMORY_USAGE}%"
|
||||
|
||||
# GPU info
|
||||
GPU_USAGE=$(cat /sys/class/drm/card1/device/gpu_busy_percent)
|
||||
GPU_VRAM_USED=$(cat /sys/class/drm/card1/device/mem_info_vram_used)
|
||||
GPU_VRAM_TOTAL=$(cat /sys/class/drm/card1/device/mem_info_vram_total)
|
||||
GPU_VRAM_USAGE=$((GPU_VRAM_USED * 100 / GPU_VRAM_TOTAL))
|
||||
|
||||
|
||||
echo " ${GPU_USAGE}% ${GPU_VRAM_USAGE}%"
|
||||
|
||||
# Battery time: find battery device via upower and parse "time to full" / "time to empty"
|
||||
# fallback to sysfs if upower not available
|
||||
BAT_PATH=""
|
||||
if command -v upower >/dev/null 2>&1; then
|
||||
BAT_PATH=$(upower -e | grep -E "battery|BAT" | head -n1)
|
||||
fi
|
||||
|
||||
if [ -z "$BAT_PATH" ]; then
|
||||
# try linux sysfs battery status file
|
||||
if [ -r /sys/class/power_supply/BAT0/status ]; then
|
||||
BAT_STATUS_FILE="/sys/class/power_supply/BAT0/status"
|
||||
else
|
||||
BAT_STATUS_FILE=""
|
||||
fi
|
||||
BATTERY_STATUS=""
|
||||
if [ -n "$BAT_STATUS_FILE" ]; then
|
||||
BATTERY_STATUS=$(cat "$BAT_STATUS_FILE")
|
||||
fi
|
||||
else
|
||||
# use upower to read battery properties
|
||||
BATTERY_STATUS=$(upower -i "$BAT_PATH" | awk -F: '/state:/ {gsub(/^[ \t]+|[ \t]+$/,"",$2); print $2; exit}')
|
||||
fi
|
||||
|
||||
if [ "$BATTERY_STATUS" = "charging" ] || [ "$BATTERY_STATUS" = "Charging" ]; then
|
||||
if [ -n "$BAT_PATH" ]; then
|
||||
# get everything after the colon and trim
|
||||
TIME_TO_FULL=$(upower -i "$BAT_PATH" | sed -n 's/^[ \t]*time to full:[ \t]*//Ip')
|
||||
else
|
||||
TIME_TO_FULL=""
|
||||
fi
|
||||
if [ -n "$TIME_TO_FULL" ]; then
|
||||
echo " ${TIME_TO_FULL} to full"
|
||||
else
|
||||
echo " Charging"
|
||||
fi
|
||||
elif [ "$BATTERY_STATUS" = "discharging" ] || [ "$BATTERY_STATUS" = "Discharging" ]; then
|
||||
if [ -n "$BAT_PATH" ]; then
|
||||
TIME_TO_EMPTY=$(upower -i "$BAT_PATH" | sed -n 's/^[ \t]*time to empty:[ \t]*//Ip')
|
||||
else
|
||||
TIME_TO_EMPTY=""
|
||||
fi
|
||||
if [ -n "$TIME_TO_EMPTY" ]; then
|
||||
echo " ${TIME_TO_EMPTY} to empty"
|
||||
else
|
||||
echo " Discharging"
|
||||
fi
|
||||
fi
|
||||
|
||||
# Check if internet is up by pinging a reliable host
|
||||
if ping -c 1 -W 1 woodburn.au > /dev/null 2>&1; then
|
||||
INTERNET_STATUS="up"
|
||||
else
|
||||
INTERNET_STATUS="down"
|
||||
fi
|
||||
|
||||
# Get WIFI SSID if connected
|
||||
echo " Internet: ${INTERNET_STATUS}"
|
||||
|
||||
# Get network info for each active interface
|
||||
for IFACE in $(ls /sys/class/net/ | grep -E '^(en|wl|wg|tailscale|tun)'); do
|
||||
IFACE_STATE=""
|
||||
# safe read operstate
|
||||
if [ -r "/sys/class/net/$IFACE/operstate" ]; then
|
||||
IFACE_STATE=$(cat "/sys/class/net/$IFACE/operstate")
|
||||
fi
|
||||
# show physical interfaces when up, and always show virtual interfaces (tailscale/wg/tun)
|
||||
if [ "$IFACE_STATE" = "up" ] || [[ "$IFACE" == tailscale* ]] || [[ "$IFACE" == wg* ]] || [[ "$IFACE" == tun* ]]; then
|
||||
RX_BYTES=$(cat "/sys/class/net/$IFACE/statistics/rx_bytes" 2>/dev/null || echo 0)
|
||||
TX_BYTES=$(cat "/sys/class/net/$IFACE/statistics/tx_bytes" 2>/dev/null || echo 0)
|
||||
RX_HR=$(numfmt --to=iec --suffix=B "$RX_BYTES")
|
||||
TX_HR=$(numfmt --to=iec --suffix=B "$TX_BYTES")
|
||||
|
||||
echo " ${IFACE}: ${RX_HR} ${TX_HR}"
|
||||
fi
|
||||
done
|
||||
|
||||
# curl https://wttr.in/Canberra\?format\="%l:+%t+UV:+%u"
|
||||
@@ -1,4 +1,4 @@
|
||||
# hyprlang noerror true
|
||||
|
||||
|
||||
# Default floating rules to stop windows being too large or small
|
||||
windowrulev2 = size <80% <80%,floating:1
|
||||
@@ -28,24 +28,17 @@ windowrulev2 = move onscreen cursor,class:^(brave-)(.*)(-.*)$
|
||||
|
||||
windowrulev2 = move onscreen cursor -50% 0,class:^(com.nextcloud.desktopclient.nextcloud)$
|
||||
windowrulev2 = float,class:^(com.nextcloud.desktopclient.nextcloud)$
|
||||
windowrulev2 = size 800px, 500px,class:^(com.nextcloud.desktopclient.nextcloud)$
|
||||
|
||||
# # Start windows
|
||||
stickyrule = class:discord,5
|
||||
stickyrule = class:vesktop,5
|
||||
stickyrule = class:org.telegram.desktop,5
|
||||
stickyrule = class:Slack,5
|
||||
|
||||
windowrule = size 800 500,class:^(com.nextcloud.desktopclient.nextcloud)$
|
||||
|
||||
workspace = special:gromit, gapsin:0, gapsout:0, shadow:0, on-created-empty: gromit-mpx -a
|
||||
windowrule = noblur, class:^(Gromit-mpx)$
|
||||
windowrule = opacity 1 override, 1 override, class:^(Gromit-mpx)$
|
||||
windowrule = opacity 1 override 1 override, class:^(Gromit-mpx)$
|
||||
windowrule = noshadow, class:^(Gromit-mpx)$
|
||||
windowrule = size 100% 100%, class:^(Gromit-mpx)$
|
||||
|
||||
|
||||
# Floating broken windows
|
||||
windowrule = opacity 1 override 1 override class:^(xdg-desktop-portal-gtk)$
|
||||
windowrule = opacity 1 override 1 override, class:^(xdg-desktop-portal-gtk)$
|
||||
windowrule = stayfocused, class:^(xdg-desktop-portal-gtk)$
|
||||
windowrule = stayfocused, class:^(soffice)$
|
||||
windowrule = stayfocused, class:^(virt-manager)$, title:^$
|
||||
@@ -60,23 +53,21 @@ windowrulev2 = stayfocused, class:^(Sparrow)$, title:^$, xwayland:1
|
||||
|
||||
|
||||
# No Opacity windowrules
|
||||
windowrule = opacity 1 override 1 override class:brave-browser
|
||||
windowrule = opacity 1 override 1 override class:mpv
|
||||
windowrule = opacity 1 override 1 override class:virt-manager
|
||||
windowrule = opacity 1 override 1 override class:^(Bootstrap Studio)$
|
||||
windowrule = opacity 1 override 1 override class:^(Minecraft)(.*)$
|
||||
windowrule = opacity 1 override 1 override class:^(gimp)$
|
||||
windowrule = opacity 1 override 1 override class:^(com.obsproject.Studio)$
|
||||
windowrule = opacity 1 override 1 override class:^$
|
||||
windowrule = opacity 1 override 1 override, class:^(brave-browser)$
|
||||
windowrule = opacity 1 override 1 override, class:^(mpv)$
|
||||
windowrule = opacity 1 override 1 override, class:^(virt-manager)$
|
||||
windowrule = opacity 1 override 1 override, class:^(Bootstrap Studio)$
|
||||
windowrule = opacity 1 override 1 override, class:^(Minecraft)(.*)$
|
||||
windowrule = opacity 1 override 1 override, class:^(gimp)$
|
||||
windowrule = opacity 1 override 1 override, class:^(com.obsproject.Studio)$
|
||||
windowrule = opacity 1 override 1 override, class:^$
|
||||
|
||||
|
||||
# Disable opacity for Alacritty (as it already has a transparent background)
|
||||
windowrule = opacity 1 override 0.75 override class:^(Alacritty)$
|
||||
windowrule = opacity 1 override 0.75 override, class:^(Alacritty)$
|
||||
|
||||
workspace = special:terminal, on-created-empty: alacritty
|
||||
|
||||
# hyprlang noerror false
|
||||
|
||||
# Tags for opacity
|
||||
windowrule = opacity 0.1 override 0.1 override, tag:opacity:0.1
|
||||
windowrule = opacity 0.2 override 0.2 override, tag:opacity:0.2
|
||||
@@ -89,6 +80,21 @@ windowrule = opacity 0.8 override 0.8 override, tag:opacity:0.8
|
||||
windowrule = opacity 0.9 override 0.9 override, tag:opacity:0.9
|
||||
windowrule = opacity 1 override 1 override, tag:opacity:1
|
||||
|
||||
|
||||
# freeRDP - Remote Desktop Protocol Client
|
||||
windowrule = float, class:^(xfreerdp)$
|
||||
# match by X11 WM_CLASS you set in xfreerdp
|
||||
windowrule = float, class:^(Autodesk Fusion)$
|
||||
windowrule = center, class:^(Autodesk Fusion)$
|
||||
# prevent tiling / auto-fullscreen for these windows
|
||||
#windowrulev2 = disableautotile, xclass:Autodesk Fusion
|
||||
windowrule = float, class:^(Autodesk Fusion)$
|
||||
# optionally force borderless (if you prefer)
|
||||
windowrule = noborder, class:^(Autodesk Fusion)$
|
||||
|
||||
|
||||
|
||||
|
||||
#! (Still doesn't work) Add org.kde.kdeconnect.daemon for KDE connect pointer
|
||||
windowrule = noblur, class:^(org.kde.kdeconnect.daemon)$ #As it is transparent it will prevent it blurring so you can see what you are ponting at
|
||||
windowrule = nofocus,class:^(org.kde.kdeconnect.daemon)$ # Disables focus so if you have the option to dim on focus it will not dim the window behind it
|
||||
|
||||
Reference in New Issue
Block a user