diff --git a/modules/wm/hyprland/config/eww/README.md b/modules/wm/hyprland/config/eww/README.md deleted file mode 100644 index e5a42e7..0000000 --- a/modules/wm/hyprland/config/eww/README.md +++ /dev/null @@ -1,8 +0,0 @@ -# Eww config file structure -```bash -eww.yuck -> calls eww_windows -eww_windows.yuck -> calls widgets, defines all windows -eww_widgets.yuck -> calls eww_variables, defines all widgets -eww_variables.yuck -> defines all variabes -scripts/ -> contains all scripts used by variables/buttons/others -``` diff --git a/modules/wm/hyprland/config/eww/eww.scss b/modules/wm/hyprland/config/eww/eww.scss deleted file mode 100644 index 2eb9113..0000000 --- a/modules/wm/hyprland/config/eww/eww.scss +++ /dev/null @@ -1,92 +0,0 @@ -$base: #24273a; -$text: #cad3f5; -$pink: #f5bde6; -$mauve: #c6a0f6; -$red: #ed8796; -$maroon: #ee99a0; -$peach: #f5a97f; -$yellow: #eed49f; -$green: #a6da95; -$teal: #8bd5ca; -$sky: #91d7e3; -$sapphire: #7dc4e4; -$blue: #8aadf4; -$lavender: #b7bdf8; -$text: #cad3f5; -$subtext1: #b8c0e0; -$subtext0: #a5adcb; -$overlay2: #939ab7; -$overlay1: #8087a2; -$overlay0: #6e738d; -$surface2: #5b6078; -$surface1: #494d64; -$surface0: #363a4f; -$base: rgba(36, 39, 58, 0.99); -$mantle: #1e2030; -$crust: #181926; - -$border-radius: 10px; - -* { - all: unset; - font-family: "JetBrains Mono"; -} - -window { - background: $base; - color: $text; - border-radius: $border-radius; - border: 3px solid $lavender; -} - -.uinfo { - font-size: 1.25rem; -} - -.cpu { - padding: 19px 1px; -} - -.metric scale trough highlight { - all: unset; - color: $text; - background: linear-gradient(90deg, $lavender 0%, $mauve 100%); - border-radius: $border-radius; -} - -.metric scale trough { - all: unset; - background-color: $surface0; - min-height: 10px; - min-width: 100px; - margin-left: 10px; - margin-right: 5px; - border-radius: $border-radius; -} - -.power { - padding: 0px 9px; -} - -.quote-text { - padding: 15px; - font-size: 1rem; - font-style: italic; - font-weight: 600; - color: $lavender; -} - -// --- Uinfo styling --- -.uinfo-host { - color: $lavender; - font-style: italic; -} - -.uinfo-hr { - color: $mauve; - font-weight: bold; -} - -.uinfo-date, .uinfo-ws, .uinfo-win, .uinfo-time { - color: $lavender; -} diff --git a/modules/wm/hyprland/config/eww/eww.yuck b/modules/wm/hyprland/config/eww/eww.yuck deleted file mode 100644 index 1d14c48..0000000 --- a/modules/wm/hyprland/config/eww/eww.yuck +++ /dev/null @@ -1,2 +0,0 @@ -;;;; Including Window script, which calls everyone else -(include "/home/horseman/.config/eww/eww_windows.yuck") diff --git a/modules/wm/hyprland/config/eww/eww_variables.yuck b/modules/wm/hyprland/config/eww/eww_variables.yuck deleted file mode 100644 index 1e73737..0000000 --- a/modules/wm/hyprland/config/eww/eww_variables.yuck +++ /dev/null @@ -1,50 +0,0 @@ -(defvar hostname "") - -(defpoll quote_text :interval "3600s" `hyprctl splash`) - -(defpoll gpu_load :interval "1s" `gpustat --json | jq '.gpus[]."utilization.gpu"'`) - -(defpoll host - :initial-value "" - :interval "1h" - - `echo $(whoami)@$(hostname)` -) - -(defpoll time - :interval "1s" - :initial-value "" - - `date +'%H:%M:%S'` -) - -(defpoll workspace - :interval "1s" - :initial-value "" - - `hyprctl activeworkspace -j | jq '.name' | sed -e 's/"//g'` -) - -(defpoll clients - :interval "1s" - :initial-value "" - - `hyprctl clients -j | jq '.[].address' | wc -l` -) - -(defpoll TODAY :interval "1s" `date +'%d %b %y'`) -(defpoll distro :interval "12h" `nixos-version | sed -r 's/^(.....).*?\\((.*?)\\)/NixOS \\1/'`) - -(defpoll sound - :interval ".25s" - :initial-value "images/sound-lo.svg" - - `./scripts/volume.sh` -) - -(defpoll wifi - :interval "1s" - :initial-value "images/ethernet.svg" - - `./scripts/wifi.sh` -) diff --git a/modules/wm/hyprland/config/eww/eww_widgets.yuck b/modules/wm/hyprland/config/eww/eww_widgets.yuck deleted file mode 100644 index 3ff417c..0000000 --- a/modules/wm/hyprland/config/eww/eww_widgets.yuck +++ /dev/null @@ -1,86 +0,0 @@ -; -> WIDGETS FOR EWW <- ; - -;;;; Imports -(include "/home/horseman/.config/eww/eww_variables.yuck") - -;;;; Metric (cpu, ram, etc bars) constructor widget -(defwidget metric [label value ?onchange] - (box :orientation "h" :class "metric" :space-evenly false - (box :class "label" label) - (scale :min 0 :max 101 :active {onchange != ""} :value value :onchange onchange))) - -(defwidget power [] - (centerbox :class "bg-box" - (box :orientation "h" :space-evenly false :valign "center" :halign "start" :spacing 5 - (button :onclick "shutdown now &" (image :path "images/shutdown.svg")) - (button :onclick "reboot &" (image :path "images/reboot.svg")) - (button :onclick "hyprlock &" (image :path "images/lock.svg")) - ) - - "" - - (box :orientation "h" :space-evenly false :valign "center" :halign "end" :spacing 5 - (button :onclick "kitty pulsemixer &" (image :path {sound} )) - (button :onclick "" (image :path {wifi})) - ) - ) -) - -;;;; User information fetch widget - -(defwidget uinfo [] - (box :class "uinfo" :orientation "v" :space-evenly false :halign "center" :valign "center" - (label :class "uinfo-host" :text {host} :halign "center" :valign "center" :wrap "false" :limit-width 25) - (label :class "uinfo-hr" :text "─────────────" :halign "center" :valign "center" :wrap "false" :limit-width 25) - - ;; Tags for values - (box :orientation "h" :space-evenly "false" :spacing 10 - (box :orientation "v" :class "fetch" :spacing 2 - (image :path "images/workspace.svg") - (image :path "images/window.svg") - (image :path "images/date.svg") - (image :path "images/time.svg") - ) - - ;; Fetch Values - (box :orientation "v" :class "fetch" - (label :class "uinfo-ws" :halign "start" :text " Workspace ${workspace}") - (label :class "uinfo-win" :halign "start" :text " ${clients} Windows") - (label :class "uinfo-date" :halign "start" :text " ${TODAY}") - (label :class "uinfo-time" :halign "start" :text " ${time}") - )))) - -;;;; System Information Widget - -(defwidget sys [] - (box :class "cpu" :orientation "v" :space-evenly false :halign "center" :valign "center" - (box :space-evenly false (image :path "images/cpu.svg")(metric :label "" :value {EWW_CPU.avg}) ) - (box :space-evenly false (image :path "images/ram.svg")(metric :label "" :value {EWW_RAM.used_mem_perc}) ) - (box :space-evenly false (image :path "images/disk.svg")(metric :label "" :value {EWW_DISK["/"].used_perc}) ) - (box :space-evenly false :visible { hostname == "luna" } (image :path { EWW_BATTERY.BAT1.status == "Discharging" ? "images/battery.svg" : "images/charging.svg" })(metric :label "" :value {EWW_BATTERY.BAT1.capacity}) ) - (box :space-evenly false :visible { hostname == "terra" } (image :path "images/gpu.svg")(metric :label "" :value gpu_load) ) - ) -) - -;;;; Random Quote Widget - -(defwidget quote [] - (box :class "quote" :orientation "v" :space-evenly false :halign "center" :valign "center" - (label :class "quote-text" :text "${quote_text}" :wrap true))) - -;;;; QuickSettings widget -(defwidget quicksettings [] - (box :orientation "h" :space-evenly true :class "quicksettings" :spacing "10" :halign "center" :valign "center" - (button :onclick "playerctl previous &" (image :path "images/prev.svg")) - (button :onclick "playerctl play-pause &" (image :path "images/play.svg")) - (button :onclick "playerctl next &" (image :path "images/next.svg")))) - -;;;; AppBar widget -(defwidget appbar [] - (box :orientation "h" :space-evenly false :class "appbar" :spacing "10" :halign "center" :valign "center" - (button :onclick "firefox &" (image :path "images/firefox.svg")) - (button :onclick "kitty vim &" (image :path "images/vim.svg")) - (button :onclick "kitty &" (image :path "images/kitty.svg")) - ) -) - diff --git a/modules/wm/hyprland/config/eww/eww_windows.yuck b/modules/wm/hyprland/config/eww/eww_windows.yuck deleted file mode 100644 index 5aa3193..0000000 --- a/modules/wm/hyprland/config/eww/eww_windows.yuck +++ /dev/null @@ -1,72 +0,0 @@ -; -> WINDOWS FOR EWW WIDGETS <- ; - -(include "/home/horseman/.config/eww/eww_widgets.yuck") - -(defwindow fetch - :wm-ignore: true - :monitor 0 - :stacking "overlay" - :geometry (geometry :x "10px" - :y "70px" - :width "170px" - :height "200px" - :anchor "top left") -(uinfo)) - -(defwindow sys - :class "cpu-win" - :wm-ignore true - :monitor 0 - :stacking "overlay" - :geometry (geometry :x "190px" - :y "280px" - :width "170px" - :height "140px" - :anchor "top left") -(sys)) - -(defwindow quote - :wm-ignore true - :monitor 0 - :stacking "overlay" - :geometry (geometry :x "190px" - :y "70px" - :width "170px" - :height "200px" - :anchor "top left") -(quote)) - -(defwindow quicksettings - :wm-ignore true - :monitor 0 - :stacking "overlay" - :geometry (geometry :x "10px" - :y "280px" - :width "170px" - :height "65px" - :anchor "top left") -(quicksettings)) - -(defwindow appbar - :wm-ignore true - :monitor 0 - :stacking "overlay" - :geometry (geometry :x "10px" - :y "355px" - :width "170px" - :height "65px" - :anchor "top left") -(appbar)) - -(defwindow power - :class "bg" - :wm-ignore true - :monitor 0 - :stacking "overlay" - :geometry (geometry :x "10px" - :y "10px" - :width "350px" - :height "50px" - :anchor "top left") -(power)) - diff --git a/modules/wm/hyprland/config/eww/images/battery.svg b/modules/wm/hyprland/config/eww/images/battery.svg deleted file mode 100644 index fa6e08b..0000000 --- a/modules/wm/hyprland/config/eww/images/battery.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/charging.svg b/modules/wm/hyprland/config/eww/images/charging.svg deleted file mode 100644 index 352cff4..0000000 --- a/modules/wm/hyprland/config/eww/images/charging.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/cpu.svg b/modules/wm/hyprland/config/eww/images/cpu.svg deleted file mode 100644 index 3d61ed1..0000000 --- a/modules/wm/hyprland/config/eww/images/cpu.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/date.svg b/modules/wm/hyprland/config/eww/images/date.svg deleted file mode 100644 index 9e1db09..0000000 --- a/modules/wm/hyprland/config/eww/images/date.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/disk.svg b/modules/wm/hyprland/config/eww/images/disk.svg deleted file mode 100644 index 4bcfb55..0000000 --- a/modules/wm/hyprland/config/eww/images/disk.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/ethernet.svg b/modules/wm/hyprland/config/eww/images/ethernet.svg deleted file mode 100644 index fb576c3..0000000 --- a/modules/wm/hyprland/config/eww/images/ethernet.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/firefox.svg b/modules/wm/hyprland/config/eww/images/firefox.svg deleted file mode 100644 index 96287d7..0000000 --- a/modules/wm/hyprland/config/eww/images/firefox.svg +++ /dev/null @@ -1,107 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/gpu.svg b/modules/wm/hyprland/config/eww/images/gpu.svg deleted file mode 100644 index d686acf..0000000 --- a/modules/wm/hyprland/config/eww/images/gpu.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/kitty.svg b/modules/wm/hyprland/config/eww/images/kitty.svg deleted file mode 100644 index ba0088e..0000000 --- a/modules/wm/hyprland/config/eww/images/kitty.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/modules/wm/hyprland/config/eww/images/lock.svg b/modules/wm/hyprland/config/eww/images/lock.svg deleted file mode 100644 index 1a92d14..0000000 --- a/modules/wm/hyprland/config/eww/images/lock.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/next.svg b/modules/wm/hyprland/config/eww/images/next.svg deleted file mode 100644 index f821dfb..0000000 --- a/modules/wm/hyprland/config/eww/images/next.svg +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/play.svg b/modules/wm/hyprland/config/eww/images/play.svg deleted file mode 100644 index b6836c7..0000000 --- a/modules/wm/hyprland/config/eww/images/play.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/modules/wm/hyprland/config/eww/images/prev.svg b/modules/wm/hyprland/config/eww/images/prev.svg deleted file mode 100644 index 38d065f..0000000 --- a/modules/wm/hyprland/config/eww/images/prev.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/ram.svg b/modules/wm/hyprland/config/eww/images/ram.svg deleted file mode 100644 index 6d7f3f8..0000000 --- a/modules/wm/hyprland/config/eww/images/ram.svg +++ /dev/null @@ -1,72 +0,0 @@ - - - - - - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/reboot.svg b/modules/wm/hyprland/config/eww/images/reboot.svg deleted file mode 100644 index 8039ef6..0000000 --- a/modules/wm/hyprland/config/eww/images/reboot.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/shutdown.svg b/modules/wm/hyprland/config/eww/images/shutdown.svg deleted file mode 100644 index d0eb135..0000000 --- a/modules/wm/hyprland/config/eww/images/shutdown.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/sound-hi.svg b/modules/wm/hyprland/config/eww/images/sound-hi.svg deleted file mode 100644 index 5cc795d..0000000 --- a/modules/wm/hyprland/config/eww/images/sound-hi.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/sound-lo.svg b/modules/wm/hyprland/config/eww/images/sound-lo.svg deleted file mode 100644 index 9a34dbe..0000000 --- a/modules/wm/hyprland/config/eww/images/sound-lo.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/sound-off.svg b/modules/wm/hyprland/config/eww/images/sound-off.svg deleted file mode 100644 index 4ea6536..0000000 --- a/modules/wm/hyprland/config/eww/images/sound-off.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/time.svg b/modules/wm/hyprland/config/eww/images/time.svg deleted file mode 100644 index 3cb6b43..0000000 --- a/modules/wm/hyprland/config/eww/images/time.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/vim.svg b/modules/wm/hyprland/config/eww/images/vim.svg deleted file mode 100644 index fb226d9..0000000 --- a/modules/wm/hyprland/config/eww/images/vim.svg +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/wifi-1.svg b/modules/wm/hyprland/config/eww/images/wifi-1.svg deleted file mode 100644 index be6f79a..0000000 --- a/modules/wm/hyprland/config/eww/images/wifi-1.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/wifi-2.svg b/modules/wm/hyprland/config/eww/images/wifi-2.svg deleted file mode 100644 index ce55ce8..0000000 --- a/modules/wm/hyprland/config/eww/images/wifi-2.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/wifi-3.svg b/modules/wm/hyprland/config/eww/images/wifi-3.svg deleted file mode 100644 index 68e0746..0000000 --- a/modules/wm/hyprland/config/eww/images/wifi-3.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/wifi-4.svg b/modules/wm/hyprland/config/eww/images/wifi-4.svg deleted file mode 100644 index eecd0e1..0000000 --- a/modules/wm/hyprland/config/eww/images/wifi-4.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/wifi-off.svg b/modules/wm/hyprland/config/eww/images/wifi-off.svg deleted file mode 100644 index f670f7e..0000000 --- a/modules/wm/hyprland/config/eww/images/wifi-off.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/window.svg b/modules/wm/hyprland/config/eww/images/window.svg deleted file mode 100644 index 54ee737..0000000 --- a/modules/wm/hyprland/config/eww/images/window.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/images/workspace.svg b/modules/wm/hyprland/config/eww/images/workspace.svg deleted file mode 100644 index 6baa9c0..0000000 --- a/modules/wm/hyprland/config/eww/images/workspace.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/modules/wm/hyprland/config/eww/scripts/open.sh b/modules/wm/hyprland/config/eww/scripts/open.sh deleted file mode 100755 index 660a7f2..0000000 --- a/modules/wm/hyprland/config/eww/scripts/open.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh - -eww update hostname="$(hostname)" - -eww open-many quote quicksettings appbar fetch sys power diff --git a/modules/wm/hyprland/config/eww/scripts/volume.sh b/modules/wm/hyprland/config/eww/scripts/volume.sh deleted file mode 100755 index 6c1c7ff..0000000 --- a/modules/wm/hyprland/config/eww/scripts/volume.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh - -volume=$(($(wpctl get-volume @DEFAULT_SINK@ | sed -r 's/Volume: (0|1)\.(..)/\1\2/; s/^(0)//g'))) - -if (( $volume == 0 )); then - echo 'images/sound-off.svg' - exit 0 -fi - -if (( $volume < 50 )); then - echo 'images/sound-lo.svg' - exit 0 -fi - -echo 'images/sound-hi.svg' diff --git a/modules/wm/hyprland/config/eww/scripts/wifi.sh b/modules/wm/hyprland/config/eww/scripts/wifi.sh deleted file mode 100755 index 91e1aa7..0000000 --- a/modules/wm/hyprland/config/eww/scripts/wifi.sh +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/sh - -strength=$(($(iwconfig wlo1 | grep 'Link Quality' | sed -r 's/.*?Link Quality=(.*?)\/.*$/\1/'))) -lines=$(($(iwconfig wlo1 | grep 'Link Quality' | sed -r 's/.*?Link Quality=(.*?)\/.*$/\1/' | wc -l))) - -if (( $lines == 0 )); then - echo 'images/wifi-off.svg' - exit 0 -fi - -if (( $strength < 18 )); then - echo 'images/wifi-1.svg' - exit 0 -fi - -if (( $strength < 35 )); then - echo 'images/wifi-2.svg' - exit 0 -fi - -if (( $strength < 53 )); then - echo 'images/wifi-3.svg' - exit 0 -fi - -if (( $strength < 70 )); then - echo 'images/wifi-4.svg' - exit 0 -fi - diff --git a/modules/wm/hyprland/default.nix b/modules/wm/hyprland/default.nix index 223a8e1..b8b5afa 100644 --- a/modules/wm/hyprland/default.nix +++ b/modules/wm/hyprland/default.nix @@ -27,7 +27,6 @@ in { security.polkit.enable = true; environment.systemPackages = with pkgs; [ brightnessctl - eww fortune hypridle hyprlock @@ -49,7 +48,6 @@ in { horseman.wm.hyprland.config = { execOnce = [ "hyprpaper" - "eww daemon" "hypridle" "hyprpaper" "swaync" diff --git a/modules/wm/hyprland/keybindings.nix b/modules/wm/hyprland/keybindings.nix index 753e5a9..42dd1e6 100644 --- a/modules/wm/hyprland/keybindings.nix +++ b/modules/wm/hyprland/keybindings.nix @@ -32,7 +32,7 @@ in { mods = ["SUPER"]; key = "SPACE"; dispatcher = "exec"; - params = "(eww close-all && pkill wofi) || (~/.config/eww/scripts/open.sh; wofi --show drun; eww close-all)"; + params = "pkill wofi || wofi --show drun"; } {