From b1671e8c9608907664fe371a43be740c985e388e Mon Sep 17 00:00:00 2001 From: Eriq Taing Date: Sun, 18 May 2025 16:04:08 -0400 Subject: [PATCH] Moved to base image for fedora provided by Red Hat. Removed some scripts and waybar for hyprpanel. --- files/system/etc/xdg/waybar/config.jsonc | 100 -------------- files/system/etc/xdg/waybar/style.css | 129 ------------------ files/system/etc/xdg/waybar/tokyonight.css | 15 -- .../hyprland.conf.d/keybinds.conf | 2 - .../scripts/hypr_power/hypr_close_clients | 18 --- .../scripts/hypr_power/hypr_logout | 5 - .../scripts/hypr_power/hypr_reboot | 5 - .../scripts/hypr_power/hypr_shutdown | 5 - .../scripts/load-kwallet-apps.sh | 3 - .../hypr-hydro-os/scripts/load-kwallet.sh | 5 - .../usr/share/hypr-hydro-os/scripts/local-lua | 4 - .../usr/share/hypr-hydro-os/scripts/menu.lua | 27 ---- .../share/hypr-hydro-os/scripts/powermenu.lua | 14 -- .../{waybar.service => hyprpanel.service} | 5 +- .../user/sway-notification-center.service | 16 --- recipes/recipe.yml | 6 +- 16 files changed, 5 insertions(+), 354 deletions(-) delete mode 100644 files/system/etc/xdg/waybar/config.jsonc delete mode 100644 files/system/etc/xdg/waybar/style.css delete mode 100644 files/system/etc/xdg/waybar/tokyonight.css delete mode 100755 files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_close_clients delete mode 100755 files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_logout delete mode 100755 files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_reboot delete mode 100755 files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_shutdown delete mode 100755 files/system/usr/share/hypr-hydro-os/scripts/load-kwallet-apps.sh delete mode 100755 files/system/usr/share/hypr-hydro-os/scripts/load-kwallet.sh delete mode 100755 files/system/usr/share/hypr-hydro-os/scripts/local-lua delete mode 100644 files/system/usr/share/hypr-hydro-os/scripts/menu.lua delete mode 100644 files/system/usr/share/hypr-hydro-os/scripts/powermenu.lua rename files/systemd/user/{waybar.service => hyprpanel.service} (70%) delete mode 100644 files/systemd/user/sway-notification-center.service diff --git a/files/system/etc/xdg/waybar/config.jsonc b/files/system/etc/xdg/waybar/config.jsonc deleted file mode 100644 index 11c477e..0000000 --- a/files/system/etc/xdg/waybar/config.jsonc +++ /dev/null @@ -1,100 +0,0 @@ -// -*- mode: jsonc -*- -{ - "layer": "top", // Waybar at top layer - // "position": "bottom", // Waybar position (top|bottom|left|right) - "height": 52, // Waybar height (to be removed for auto height) - // "width": 1280, // Waybar width - "spacing": 0, // Gaps between modules (4px) - // Choose the order of the modules - "modules-left": [ - "cpu", - "memory", - "hyprland/workspaces", - "hyprland/window" - ], - "modules-center": [ - "mpris" - ], - "modules-right": [ - "tray", - "gamemode", - "wireplumber", - "custom/notification", - "clock" - ], - //"reload_style_on_change": true, - "hyprland/window":{ - "separate-outputs": true, - "hide-empty-text": true, - }, - "tray": { - // "icon-size": 21, - "spacing": 10 - }, - "clock": { - // "timezone": "America/New_York", - "format": "{:%I : %M %p %Y-%m-%d}", - "tooltip-format": "{:%Y %B}\n{calendar}" - }, - "cpu": { - "format": "{usage}% ", - "tooltip": false - }, - "memory": { - "format": "{}% " - }, - "temperature": { - // "thermal-zone": 2, - // "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input", - "critical-threshold": 80, - // "format-critical": "{temperatureC}°C {icon}", - "format": "{temperatureC}°C {icon}", - "format-icons": ["", "", ""] - }, - "network": { - // "interface": "wlp2*", // (Optional) To force the use of this interface - "format-wifi": "{essid} ({signalStrength}%) ", - "format-ethernet": "{ipaddr}/{cidr} ", - "tooltip-format": "{ifname} via {gwaddr} ", - "format-linked": "{ifname} (No IP) ", - "format-disconnected": "Disconnected ⚠", - "format-alt": "{ifname}: {ipaddr}/{cidr}" - }, - "wireplumber": { - "format": "{node_name} {volume}% {icon}", - "format-muted": "{node_name} ", - "on-click": "hyprctl dispatch -- exec flatpak run com.saivert.pwvucontrol", - "format-icons": ["", "", ""] - }, - "custom/notification": { - "tooltip": false, - "format": "{} {icon}", - "format-icons": { - "notification": "", - "none": "", - "dnd-notification": "", - "dnd-none": "", - "inhibited-notification": "", - "inhibited-none": "", - "dnd-inhibited-notification": "", - "dnd-inhibited-none": "" - }, - "return-type": "json", - "exec-if": "which swaync-client", - "exec": "swaync-client -swb", - "on-click": "swaync-client -t -sw", - "on-click-right": "swaync-client -d -sw", - "escape": true - }, - "mpris": { - "format": "{player_icon} {title} - {artist}", - "format-paused": "{status_icon} {title} - {artist}", - "player-icons": { - "default": "▶", - "mpv": "🎵" - }, - "status-icons": { - "paused": "⏸" - } - }, -} diff --git a/files/system/etc/xdg/waybar/style.css b/files/system/etc/xdg/waybar/style.css deleted file mode 100644 index 3036a72..0000000 --- a/files/system/etc/xdg/waybar/style.css +++ /dev/null @@ -1,129 +0,0 @@ -@import "tokyonight.css"; - -* { - font-family: JetBrains Mono; - font-size: 17px; - min-height: 0; -} - -window#waybar { - background-color: @transparent; - color: @theme_text_color; - margin: 0rem 0rem 0rem 0rem; -} - -#workspaces button { - color: @lavender; - border-radius: 1.5rem; - padding: 0rem 0.5rem; -} - -#workspaces button.active { - color: @sky; - border-radius: 1.5rem; -} - -#workspaces button:hover { - color: @sapphire; - border-radius: 1.5rem; -} - -#cpu, -#memory, -#custom-weather, -#wireplumber, -#custom-notification, -#custom-music, -#custom-edit-config, -#tray, -#backlight, -#clock, -#battery, -#pulseaudio, -#custom-lock, -#powermenu, -#window, -#workspaces, -#gamemode, -#mpris { - background-color: @theme_bg_color; - padding: 0.5rem 0.75rem; - margin: 0.75rem 0.25rem 0rem 0.25rem; - border-radius: 1.5rem; - border: 2px solid; -} - -window#waybar.empty #window { - background-color: transparent; - border: 0px -} - -/* left side margin */ -#cpu { - margin-left: 1rem; -} - -/* right side margin */ -#clock { - margin-right: 1rem; -} - -#cpu { - color: @green; -} - -#memory { - color: @magenta; -} - -#clock { - color: @blue; -} - -#battery { - color: @green; -} - -#battery.charging { - color: @green; -} - -#battery.warning:not(.charging) { - color: @red; -} - -#backlight { - color: @yellow; -} - -#pulseaudio { - color: @maroon; -} - -#custom-music { - color: @mauve; -} - -#custom-lock { - color: @magenta; -} - -#custom-power { - color: @red; -} - -#wireplumber { - color: @red; -} - -#custom-notification { - color: @rosewater; -} - -#custom-notification.notification { - color: @red; -} - -#custom-notification.dnd-notification { - color: @maroon; -} diff --git a/files/system/etc/xdg/waybar/tokyonight.css b/files/system/etc/xdg/waybar/tokyonight.css deleted file mode 100644 index 4a259ee..0000000 --- a/files/system/etc/xdg/waybar/tokyonight.css +++ /dev/null @@ -1,15 +0,0 @@ -@define-color foreground #313244; -@define-color background #1a1b26; -@define-color text #a9b1d6; -@define-color black #414868; -@define-color red #f7768e; -@define-color green #73daca; -@define-color yellow #e0af68; -@define-color blue #7aa2f7; -@define-color magenta #bb9af7; -@define-color cyan #7dcfff; -@define-color white #c0caf5; -@define-color sky #89dceb; -@define-color sapphire #74c7ec; -@define-color rosewater #f5e0dc; -@define-color flamingo #f2cdcd; \ No newline at end of file diff --git a/files/system/usr/share/hypr-hydro-os/hyprland.conf.d/keybinds.conf b/files/system/usr/share/hypr-hydro-os/hyprland.conf.d/keybinds.conf index 87f3aea..f86c491 100644 --- a/files/system/usr/share/hypr-hydro-os/hyprland.conf.d/keybinds.conf +++ b/files/system/usr/share/hypr-hydro-os/hyprland.conf.d/keybinds.conf @@ -5,14 +5,12 @@ $fileManager = uwsm app -- org.kde.dolphin.desktop $menu = uwsm app -- $(wofi --show drun --define=drun-print_desktop_file=true) #$menu = ags request -i launcher show $screenshot = hyprshot -m region --clipboard-only -$powermenu = /usr/share/hypr-hydro-os/scripts/local-lua /usr/share/hypr-hydro-os/scripts/powermenu.lua # See https://wiki.hyprland.org/Configuring/Keywords/ for more $mainMod = SUPER # Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more bind = $mainMod SHIFT, C, killactive, -bind = $mainMod, M, exec, $powermenu bind = $mainMod, E, exec, $fileManager bind = $mainMod, V, togglefloating, bind = $mainMod, R, exec, $menu diff --git a/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_close_clients b/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_close_clients deleted file mode 100755 index 10a5dca..0000000 --- a/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_close_clients +++ /dev/null @@ -1,18 +0,0 @@ -#!/usr/bin/env bash - -HYPRCMDS=$(hyprctl -j clients | jq -j '.[] | "dispatch closewindow address:\(.address); "') -hyprctl --batch "$HYPRCMDS" >>/tmp/hyprexitwithgrace.log 2>&1 - -notify-send "power controls" "Closing Applications..." - -sleep 2 - -COUNT=$(hyprctl clients | grep "class:" | wc -l) - -if [ "$COUNT" -eq "0" ]; then - notify-send "power controls" "Closed Applications." - return -else - notify-send "power controls" "Some apps didn't close. Not shutting down." - exit 1 -fi diff --git a/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_logout b/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_logout deleted file mode 100755 index 3c5fac5..0000000 --- a/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_logout +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env bash - -/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_close_clients - -hyprctl dispatch exit diff --git a/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_reboot b/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_reboot deleted file mode 100755 index e3add18..0000000 --- a/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_reboot +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env bash - -/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_close_clients - -systemctl reboot diff --git a/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_shutdown b/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_shutdown deleted file mode 100755 index 398d517..0000000 --- a/files/system/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_shutdown +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env bash - -/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_close_clients - -systemctl poweroff diff --git a/files/system/usr/share/hypr-hydro-os/scripts/load-kwallet-apps.sh b/files/system/usr/share/hypr-hydro-os/scripts/load-kwallet-apps.sh deleted file mode 100755 index a65b328..0000000 --- a/files/system/usr/share/hypr-hydro-os/scripts/load-kwallet-apps.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/usr/bin/env bash -# nextcloud desktop -sleep 15 && flatpak run --branch=stable --arch=x86_64 --command=nextcloud --file-forwarding com.nextcloud.desktopclient.nextcloud diff --git a/files/system/usr/share/hypr-hydro-os/scripts/load-kwallet.sh b/files/system/usr/share/hypr-hydro-os/scripts/load-kwallet.sh deleted file mode 100755 index b480b05..0000000 --- a/files/system/usr/share/hypr-hydro-os/scripts/load-kwallet.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env bash -kwalletmanager5 & -sleep 1 && exec --no-startup-id /usr/lib/pam_kwallet_init -notify-send -e --expire-time=2000 'Kwallet has been loaded. Loading dependent apps...' -sleep 2 && hyprctl dispatch closewindow class:org.kde.kwalletmanager diff --git a/files/system/usr/share/hypr-hydro-os/scripts/local-lua b/files/system/usr/share/hypr-hydro-os/scripts/local-lua deleted file mode 100755 index 7604e5e..0000000 --- a/files/system/usr/share/hypr-hydro-os/scripts/local-lua +++ /dev/null @@ -1,4 +0,0 @@ -#!/usr/bin/env bash -BIN_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &>/dev/null && pwd) - -LUA_PATH="${BIN_DIR}/?.lua;;" lua $1 diff --git a/files/system/usr/share/hypr-hydro-os/scripts/menu.lua b/files/system/usr/share/hypr-hydro-os/scripts/menu.lua deleted file mode 100644 index 1e658ba..0000000 --- a/files/system/usr/share/hypr-hydro-os/scripts/menu.lua +++ /dev/null @@ -1,27 +0,0 @@ -#!/usr/bin/env lua -local menu = {} - -function menu:clean_string(str) - str = string.gsub(str, "^%s+", "") - str = string.gsub(str, "%s+$", "") - return string.gsub(str, "[\n]+", " ") -end - -function menu:bring_menu(prompt, options) - local options_string = "" - local length = 1 - for _, value in pairs(options) do - options_string = options_string .. value .. "\n" - length = length + 1 - end - - options_string = options_string:sub(1, -2) - - local command = "echo -e '" .. options_string .. "' | wofi -dmenu -i -p '" .. prompt .. "'" - local f = assert(io.popen(command, "r")) - local s = menu:clean_string(assert(f:read("*a"))) - f:close() - return s -end - -return menu diff --git a/files/system/usr/share/hypr-hydro-os/scripts/powermenu.lua b/files/system/usr/share/hypr-hydro-os/scripts/powermenu.lua deleted file mode 100644 index c5ac902..0000000 --- a/files/system/usr/share/hypr-hydro-os/scripts/powermenu.lua +++ /dev/null @@ -1,14 +0,0 @@ -#!/usr/bin/env lua -local menu = require("menu") -local executable = { - ["Shutdown"] = "/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_shutdown", - ["Reboot"] = "/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_reboot", - ["Log out"] = "/usr/share/hypr-hydro-os/scripts/hypr_power/hypr_logout", - ["Cancel"] = "", -} - -local options = { "Shutdown", "Reboot", "Log out", "Cancel" } - -local s = menu:bring_menu("Power menu", options) - -os.execute(executable[s]) diff --git a/files/systemd/user/waybar.service b/files/systemd/user/hyprpanel.service similarity index 70% rename from files/systemd/user/waybar.service rename to files/systemd/user/hyprpanel.service index a991743..0b419e0 100644 --- a/files/systemd/user/waybar.service +++ b/files/systemd/user/hyprpanel.service @@ -1,5 +1,5 @@ [Unit] -Description=Highly customizable Wayland bar for Sway and Wlroots based compositors. +Description=A panel bar branched from AGS maintained by Hyprland devs. Documentation=man:waybar(5) # order startup after WM After=graphical-session.target @@ -8,8 +8,7 @@ After=graphical-session.target Type=exec # Repurpose XDG Autostart filtering ExecCondition=/lib/systemd/systemd-xdg-autostart-condition "wlroots:sway:Wayfire:labwc:Hyprland" "" -ExecStart=/usr/bin/waybar -ExecReload=kill -SIGUSR2 $MAINPID +ExecStart=/usr/bin/hyprpanel Restart=on-failure Slice=app-graphical.slice diff --git a/files/systemd/user/sway-notification-center.service b/files/systemd/user/sway-notification-center.service deleted file mode 100644 index 9fa6d5d..0000000 --- a/files/systemd/user/sway-notification-center.service +++ /dev/null @@ -1,16 +0,0 @@ -[Unit] -Description=A simple notification daemon with a GTK gui for notifications and the control center. -Documentation=man:swaync(1) -# order startup after WM -After=graphical-session.target - -[Service] -Type=exec -# Repurpose XDG Autostart filtering -ExecCondition=/lib/systemd/systemd-xdg-autostart-condition "wlroots:sway:Wayfire:labwc:Hyprland" "" -ExecStart=/usr/bin/swaync -Restart=on-failure -Slice=app-graphical.slice - -[Install] -WantedBy=graphical-session.target \ No newline at end of file diff --git a/recipes/recipe.yml b/recipes/recipe.yml index 8a82169..e21af3d 100644 --- a/recipes/recipe.yml +++ b/recipes/recipe.yml @@ -6,7 +6,7 @@ name: hydro-os description: This is my personal OS image. # the base image to build on top of (FROM) and the version tag to use -base-image: ghcr.io/ublue-os/bazzite-asus-nvidia +base-image: quay.io/fedora-ostree-desktops/base-atomic image-version: latest # latest is also supported if you want new updates ASAP # module configuration, executed in order @@ -23,7 +23,7 @@ modules: - https://copr.fedorainfracloud.org/coprs/erikreider/SwayNotificationCenter/repo/fedora-%OS_VERSION%/erikreider-SwayNotificationCenter-fedora-%OS_VERSION%.repo install: - hyprland-git - - waybar + - hyprpanel - neovim - SwayNotificationCenter - hyprpolkitagent @@ -41,7 +41,7 @@ modules: - type: systemd user: enabled: - - waybar.service + - hyprpanel.service - hyprpolkitagent.service - type: signing # this sets up the proper policy & signing files for signed images to work fully