Laptop powers
This commit is contained in:
parent
bdbb944ad5
commit
18dc7a1772
7 changed files with 55 additions and 20 deletions
0
common/empty-env/hyprland.d.conf
Normal file
0
common/empty-env/hyprland.d.conf
Normal file
1
host/desktop/hyprland.d.cond
Normal file
1
host/desktop/hyprland.d.cond
Normal file
|
@ -0,0 +1 @@
|
|||
|
5
host/desktop/hyprland.d.conf
Normal file
5
host/desktop/hyprland.d.conf
Normal file
|
@ -0,0 +1,5 @@
|
|||
source ~/.config/hypr/hyprland.conf
|
||||
|
||||
monitor=DP-1,3840x2160@60,0x0,1.5,transform,3
|
||||
monitor=DP-2,3840x2160@60,5280x0,1.5,transform,3
|
||||
monitor=DP-3,3840x2160@120,1440x0,1
|
11
host/laptop/hyprland.d.conf
Normal file
11
host/laptop/hyprland.d.conf
Normal file
|
@ -0,0 +1,11 @@
|
|||
source = ~/.config/hypr/hyprland.conf
|
||||
|
||||
bind = SUPER, return, exec, wezterm
|
||||
bind = SUPER, M, exit,
|
||||
|
||||
input {
|
||||
kb_options = ctrl:nocaps
|
||||
touchpad {
|
||||
natural_scroll = yes
|
||||
}
|
||||
}
|
|
@ -1,3 +1,14 @@
|
|||
#!/usr/bin/env sh
|
||||
# exec "$(dirname "$0")/../sway/init"
|
||||
exec Hyprland
|
||||
|
||||
c="$HOME/.config"
|
||||
ev="$c/hypr/hyprland.conf"
|
||||
ee="$c/lytedev-env"
|
||||
for e in "host-desktop" "host-laptop"; do
|
||||
f="$ee/$e/hyprland.d.conf"
|
||||
[ -f "$f" ] && c="$f"
|
||||
done
|
||||
|
||||
echo "Using config $c"
|
||||
|
||||
exec Hyprland -c "$c"
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
(music)))
|
||||
|
||||
(defwindow bar
|
||||
:monitor 2
|
||||
:monitor 0
|
||||
:stacking "fg"
|
||||
:exclusive true
|
||||
:geometry
|
||||
|
@ -24,10 +24,10 @@
|
|||
; TODO: get these to align properly?
|
||||
(box :class "mic" (box :class {micMuted == "false" ? "live" : "muted"} {micMuted == "false" ? " " : " "}))
|
||||
{" " + volume}
|
||||
{" " + cpu}
|
||||
{" " + ram}
|
||||
; TODO: brightness
|
||||
; TODO: battery
|
||||
{" " + round(EWW_CPU["avg"], 0) + "%"}
|
||||
{" " + round(EWW_RAM["used_mem_perc"], 0) + "%"}
|
||||
{" " + brightness + "%"}
|
||||
{" " + EWW_BATTERY["BAT0"]["capacity"] + "%"}
|
||||
))
|
||||
|
||||
(defwidget music []
|
||||
|
@ -46,11 +46,8 @@
|
|||
(deflisten micMuted :initial "false"
|
||||
"pamixer --default-source --get-mute; pactl subscribe | grep source --line-buffered | while read i; do pamixer --default-source --get-mute; done")
|
||||
|
||||
(defpoll cpu :interval "5s"
|
||||
"mpstat -o JSON | jq -r '(100 - .sysstat.hosts[0].statistics[0][\"cpu-load\"][0].idle | round | tostring)+\"%\"'")
|
||||
|
||||
(defpoll ram :interval "5s"
|
||||
"free | grep Mem | awk '{printf \"%.0f%\", $3/$2 * 100.0}'")
|
||||
|
||||
(defpoll time :interval "1s"
|
||||
"date '+%a %b %d %H:%M:%S'")
|
||||
|
||||
(defpoll brightness :interval "5s"
|
||||
"echo $((100 * ($(brightnessctl get) / $(brightnessctl max))))")
|
||||
|
|
|
@ -1,8 +1,5 @@
|
|||
# See https://wiki.hyprland.org/Configuring/Monitors/
|
||||
monitor=,preferred,auto,auto
|
||||
monitor=DP-1,3840x2160@60,0x0,1.5,transform,3
|
||||
monitor=DP-2,3840x2160@60,5280x0,1.5,transform,3
|
||||
monitor=DP-3,3840x2160@120,1440x0,1
|
||||
|
||||
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||
|
||||
|
@ -11,12 +8,8 @@ exec-once = firefox & wezterm & hyprpaper & mako & /usr/lib/polkit-kde-authentic
|
|||
exec-once = swayidle -w timeout 600 'notify-send "Locking in 30 seconds..."' timeout 630 'swaylock -f' timeout 660 'hyprctl dispatch dpms off' resume 'hyprctl dispatch dpms on' before-sleep 'swaylock -f'
|
||||
exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
|
||||
|
||||
# source = ~/.config/hypr/myColors.conf
|
||||
|
||||
# Some default env vars.
|
||||
env = XCURSOR_SIZE,24
|
||||
|
||||
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/
|
||||
input {
|
||||
kb_layout = us
|
||||
# kb_variant =
|
||||
|
@ -39,6 +32,15 @@ input {
|
|||
sensitivity = 1 # -1.0 - 1.0, 0 means no modification.
|
||||
}
|
||||
|
||||
misc {
|
||||
disable_hyprland_logo = true
|
||||
disable_splash_rendering = true
|
||||
}
|
||||
|
||||
binds {
|
||||
allow_workspace_cycles = true
|
||||
}
|
||||
|
||||
general {
|
||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||
|
||||
|
@ -161,6 +163,8 @@ bind = , XF86AudioPlay, exec, playerctl play-pause
|
|||
bind = , XF86AudioNext, exec, playerctl next
|
||||
bind = , XF86AudioPrev, exec, playerctl previous
|
||||
|
||||
bind = $mainMod, tab, workspace, previous
|
||||
|
||||
# Switch workspaces with mainMod + [0-9]
|
||||
bind = $mainMod, 1, workspace, 1
|
||||
bind = $mainMod, 2, workspace, 2
|
||||
|
@ -185,6 +189,13 @@ bind = $mainMod SHIFT, 8, movetoworkspace, 8
|
|||
bind = $mainMod SHIFT, 9, movetoworkspace, 9
|
||||
bind = $mainMod SHIFT, 0, movetoworkspace, 10
|
||||
|
||||
bind = , XF86MonBrightnessDown, exec, brightnessctl set 10%-
|
||||
bind = , XF86MonBrightnessUp, exec, brightnessctl set +10%
|
||||
bind = SHIFT, XF86MonBrightnessDown, exec, brightnessctl set 1%
|
||||
bind = SHIFT, XF86MonBrightnessUp, exec, brightnessctl set 100%
|
||||
bind = CTRL, XF86MonBrightnessDown, exec, brightnessctl set 1%-
|
||||
bind = CTRL, XF86MonBrightnessUp, exec, brightnessctl set +1%
|
||||
|
||||
bind = $mainMod SHIFT, S, exec, clipshot
|
||||
|
||||
# Scroll through existing workspaces with mainMod + scroll
|
||||
|
@ -194,4 +205,3 @@ bind = $mainMod, mouse_up, workspace, e-1
|
|||
# Move/resize windows with mainMod + LMB/RMB and dragging
|
||||
bindm = $mainMod, mouse:272, movewindow
|
||||
bindm = $mainMod, mouse:273, resizewindow
|
||||
|
||||
|
|
Reference in a new issue