fix(system): enable uwsm and fix session detection to allow VM login

- Enable programs.uwsm for session management.
- Improve SDDM theme session detection logic to be case-insensitive and more robust.
- Perform a global cleanup of 'Nnomarchy' and 'org.nnomarchy' typos across all scripts and configurations.
This commit is contained in:
Bernardo Magri
2026-04-05 11:18:41 +01:00
parent 7f086f07bf
commit 8a72a09bd8
105 changed files with 320 additions and 319 deletions

View File

@@ -1,8 +1,8 @@
#!/usr/bin/env bash
# Build the Nnomarchy Installer ISO declaratively using the flake.
# Build the Nomarchy Installer ISO declaratively using the flake.
echo "Building Nnomarchy Installer ISO..."
echo "Building Nomarchy Installer ISO..."
# The output will be a symlink named 'result' in the current directory
nix build .#nixosConfigurations.installerIso.config.system.build.isoImage

View File

@@ -19,7 +19,7 @@ WEBCAM="false"
WEBCAM_DEVICE=""
RESOLUTION=""
STOP_RECORDING="false"
RECORDING_FILE="/tmp/nnomarchy-screenrecord-filename"
RECORDING_FILE="/tmp/nomarchy-screenrecord-filename"
for arg in "$@"; do
case "$arg" in

View File

@@ -3,7 +3,7 @@
# Share clipboard, file, or folder using LocalSend. Bound to Super + Ctrl + S by default.
if (($# == 0)); then
echo "Usage: nnomarchy-cmd-share [clipboard|file|folder]"
echo "Usage: nomarchy-cmd-share [clipboard|file|folder]"
exit 1
fi

View File

@@ -1,6 +1,6 @@
#!/bin/bash
# Add an EFI boot entry for the Nnomarchy UKI, allowing the system to boot directly
# Add an EFI boot entry for the Nomarchy UKI, allowing the system to boot directly
# without a bootloader like Limine. Requires UEFI firmware and a built UKI.
if [[ ! -d /sys/firmware/efi ]]; then
@@ -23,10 +23,10 @@ if cat /sys/class/dmi/id/bios_vendor 2>/dev/null | grep -qi "Apple"; then
exit 1
fi
uki_file=$(find /boot/EFI/Linux/ -name "nnomarchy*.efi" -printf "%f\n" 2>/dev/null | head -1)
uki_file=$(find /boot/EFI/Linux/ -name "nomarchy*.efi" -printf "%f\n" 2>/dev/null | head -1)
if [[ -z $uki_file ]]; then
echo "Error: No Nnomarchy UKI found in /boot/EFI/Linux/" >&2
echo "Error: No Nomarchy UKI found in /boot/EFI/Linux/" >&2
exit 1
fi
@@ -40,6 +40,6 @@ if gum confirm "Setup direct boot (so snapshot booting must be done via bios)?";
sudo efibootmgr --create \
--disk "$disk" \
--part "$part" \
--label "Nnomarchy" \
--label "Nomarchy" \
--loader "\\EFI\\Linux\\$uki_file"
fi

View File

@@ -1,9 +1,9 @@
#!/bin/bash
# Returns drive information about a given volumne, like /dev/nvme0, which is used by nnomarchy-drive-select.
# Returns drive information about a given volumne, like /dev/nvme0, which is used by nomarchy-drive-select.
if (($# == 0)); then
echo "Usage: nnomarchy-drive-info [/dev/drive]"
echo "Usage: nomarchy-drive-info [/dev/drive]"
exit 1
else
drive="$1"

View File

@@ -1,6 +1,6 @@
#!/bin/bash
# Select a drive from a list with info that includes space and brand. Used by nnomarchy-drive-set-password.
# Select a drive from a list with info that includes space and brand. Used by nomarchy-drive-set-password.
if (($# == 0)); then
drives=$(lsblk -dpno NAME | grep -E '/dev/(sd|hd|vd|nvme|mmcblk|xv)')
@@ -11,7 +11,7 @@ fi
drives_with_info=""
while IFS= read -r drive; do
[[ -n $drive ]] || continue
drives_with_info+="$(nnomarchy-drive-info "$drive")"$'\n'
drives_with_info+="$(nomarchy-drive-info "$drive")"$'\n'
done <<<"$drives"
selected_drive="$(printf "%s" "$drives_with_info" | gum choose --header "Select drive")" || exit 1

View File

@@ -8,7 +8,7 @@ if [[ -n $encrypted_drives ]]; then
if (( $(wc -l <<<encrypted_drives) == 1 )); then
drive_to_change="$encrypted_drives"
else
drive_to_change="$(nnomarchy-drive-select "$encrypted_drives")"
drive_to_change="$(nomarchy-drive-select "$encrypted_drives")"
fi
if [[ -n $drive_to_change ]]; then

View File

@@ -1,16 +1,16 @@
#!/bin/bash
# Run a named hook, like post-update (available in ~/.config/nnomarchy/hooks/post-update).
# Run a named hook, like post-update (available in ~/.config/nomarchy/hooks/post-update).
set -e
if (( $# < 1 )); then
echo "Usage: nnomarchy-hook [name] [args...]"
echo "Usage: nomarchy-hook [name] [args...]"
exit 1
fi
HOOK=$1
HOOK_PATH="$HOME/.config/nnomarchy/hooks/$1"
HOOK_PATH="$HOME/.config/nomarchy/hooks/$1"
shift
if [[ -f $HOOK_PATH ]]; then

View File

@@ -14,4 +14,4 @@ if pgrep -x "1password" >/dev/null; then
fi
# Avoid running screensaver when locked
pkill -f org.nnomarchy.screensaver
pkill -f org.nomarchy.screensaver

View File

@@ -1,8 +1,8 @@
#!/bin/bash
# Launch the Nnomarchy Menu or takes a parameter to jump straight to a submenu.
# Launch the Nomarchy Menu or takes a parameter to jump straight to a submenu.
export PATH="$HOME/.local/share/nnomarchy/bin:$PATH"
export PATH="$HOME/.local/share/nomarchy/bin:$PATH"
# Set to true when going directly to a submenu, so we can exit directly
BACK_TO_EXIT=false
@@ -42,30 +42,30 @@ menu() {
fi
fi
echo -e "$options" | nnomarchy-launch-walker --dmenu --width 295 --minheight 1 --maxheight 630 -p "$prompt…" "${args[@]}" 2>/dev/null
echo -e "$options" | nomarchy-launch-walker --dmenu --width 295 --minheight 1 --maxheight 630 -p "$prompt…" "${args[@]}" 2>/dev/null
}
terminal() {
xdg-terminal-exec --app-id=org.nnomarchy.terminal "$@"
xdg-terminal-exec --app-id=org.nomarchy.terminal "$@"
}
present_terminal() {
nnomarchy-launch-floating-terminal-with-presentation $1
nomarchy-launch-floating-terminal-with-presentation $1
}
open_in_editor() {
notify-send -u low "Editing config file" "$1"
nnomarchy-launch-editor "$1"
nomarchy-launch-editor "$1"
}
show_learn_menu() {
case $(menu "Learn" " Keybindings\n Nnomarchy\n Hyprland\n󰣇 Arch\n Neovim\n󱆃 Bash") in
*Keybindings*) nnomarchy-menu-keybindings ;;
*Nnomarchy*) nnomarchy-launch-webapp "https://learn.omacom.io/2/the-nnomarchy-manual" ;;
*Hyprland*) nnomarchy-launch-webapp "https://wiki.hypr.land/" ;;
*Arch*) nnomarchy-launch-webapp "https://wiki.archlinux.org/title/Main_page" ;;
*Bash*) nnomarchy-launch-webapp "https://devhints.io/bash" ;;
*Neovim*) nnomarchy-launch-webapp "https://www.lazyvim.org/keymaps" ;;
case $(menu "Learn" " Keybindings\n Nomarchy\n Hyprland\n󰣇 Arch\n Neovim\n󱆃 Bash") in
*Keybindings*) nomarchy-menu-keybindings ;;
*Nomarchy*) nomarchy-launch-webapp "https://learn.omacom.io/2/the-nomarchy-manual" ;;
*Hyprland*) nomarchy-launch-webapp "https://wiki.hypr.land/" ;;
*Arch*) nomarchy-launch-webapp "https://wiki.archlinux.org/title/Main_page" ;;
*Bash*) nomarchy-launch-webapp "https://devhints.io/bash" ;;
*Neovim*) nomarchy-launch-webapp "https://www.lazyvim.org/keymaps" ;;
*) show_main_menu ;;
esac
}
@@ -82,7 +82,7 @@ show_trigger_menu() {
show_capture_menu() {
case $(menu "Capture" " Screenshot\n Screenrecord\n󰃉 Color") in
*Screenshot*) nnomarchy-cmd-screenshot ;;
*Screenshot*) nomarchy-cmd-screenshot ;;
*Screenrecord*) show_screenrecord_menu ;;
*Color*) pkill hyprpicker || hyprpicker -a ;;
*) back_to show_trigger_menu ;;
@@ -117,18 +117,18 @@ show_webcam_select_menu() {
}
show_screenrecord_menu() {
nnomarchy-cmd-screenrecord --stop-recording && exit 0
nomarchy-cmd-screenrecord --stop-recording && exit 0
case $(menu "Screenrecord" " With no audio\n With desktop audio\n With desktop + microphone audio\n With desktop + microphone audio + webcam") in
*"With no audio") nnomarchy-cmd-screenrecord ;;
*"With desktop audio") nnomarchy-cmd-screenrecord --with-desktop-audio ;;
*"With desktop + microphone audio") nnomarchy-cmd-screenrecord --with-desktop-audio --with-microphone-audio ;;
*"With no audio") nomarchy-cmd-screenrecord ;;
*"With desktop audio") nomarchy-cmd-screenrecord --with-desktop-audio ;;
*"With desktop + microphone audio") nomarchy-cmd-screenrecord --with-desktop-audio --with-microphone-audio ;;
*"With desktop + microphone audio + webcam")
local device=$(show_webcam_select_menu) || {
back_to show_capture_menu
return
}
nnomarchy-cmd-screenrecord --with-desktop-audio --with-microphone-audio --with-webcam --webcam-device="$device"
nomarchy-cmd-screenrecord --with-desktop-audio --with-microphone-audio --with-webcam --webcam-device="$device"
;;
*) back_to show_capture_menu ;;
esac
@@ -136,9 +136,9 @@ show_screenrecord_menu() {
show_share_menu() {
case $(menu "Share" " Clipboard\n File \n Folder") in
*Clipboard*) nnomarchy-cmd-share clipboard ;;
*File*) terminal bash -c "nnomarchy-cmd-share file" ;;
*Folder*) terminal bash -c "nnomarchy-cmd-share folder" ;;
*Clipboard*) nomarchy-cmd-share clipboard ;;
*File*) terminal bash -c "nomarchy-cmd-share file" ;;
*Folder*) terminal bash -c "nomarchy-cmd-share folder" ;;
*) back_to show_trigger_menu ;;
esac
}
@@ -146,21 +146,21 @@ show_share_menu() {
show_toggle_menu() {
case $(menu "Toggle" "󱄄 Screensaver\n󰔎 Nightlight\n󱫖 Idle Lock\n󰍜 Top Bar\n󱂬 Workspace Layout\n Window Gaps\n 1-Window Ratio\n󰍹 Display Scaling") in
*Screensaver*) nnomarchy-toggle-screensaver ;;
*Nightlight*) nnomarchy-toggle-nightlight ;;
*Idle*) nnomarchy-toggle-idle ;;
*Bar*) nnomarchy-toggle-waybar ;;
*Layout*) nnomarchy-hyprland-workspace-layout-toggle ;;
*Ratio*) nnomarchy-hyprland-window-single-square-aspect-toggle ;;
*Gaps*) nnomarchy-hyprland-window-gaps-toggle ;;
*Scaling*) nnomarchy-hyprland-monitor-scaling-cycle ;;
*Screensaver*) nomarchy-toggle-screensaver ;;
*Nightlight*) nomarchy-toggle-nightlight ;;
*Idle*) nomarchy-toggle-idle ;;
*Bar*) nomarchy-toggle-waybar ;;
*Layout*) nomarchy-hyprland-workspace-layout-toggle ;;
*Ratio*) nomarchy-hyprland-window-single-square-aspect-toggle ;;
*Gaps*) nomarchy-hyprland-window-gaps-toggle ;;
*Scaling*) nomarchy-hyprland-monitor-scaling-cycle ;;
*) back_to show_trigger_menu ;;
esac
}
show_hardware_menu() {
case $(menu "Toggle" " Hybrid GPU") in
*"Hybrid GPU"*) present_terminal nnomarchy-toggle-hybrid-gpu ;;
*"Hybrid GPU"*) present_terminal nomarchy-toggle-hybrid-gpu ;;
*) show_trigger_menu ;;
esac
}
@@ -171,26 +171,26 @@ show_style_menu() {
*Font*) show_font_menu ;;
*Background*) show_background_menu ;;
*Hyprland*) open_in_editor ~/.config/hypr/looknfeel.conf ;;
*Screensaver*) open_in_editor ~/.config/nnomarchy/branding/screensaver.txt ;;
*About*) open_in_editor ~/.config/nnomarchy/branding/about.txt ;;
*Screensaver*) open_in_editor ~/.config/nomarchy/branding/screensaver.txt ;;
*About*) open_in_editor ~/.config/nomarchy/branding/about.txt ;;
*) show_main_menu ;;
esac
}
show_theme_menu() {
nnomarchy-launch-walker -m menus:nnomarchythemes --width 800 --minheight 400
nomarchy-launch-walker -m menus:nomarchythemes --width 800 --minheight 400
}
show_background_menu() {
nnomarchy-launch-walker -m menus:nnomarchyBackgroundSelector --width 800 --minheight 400
nomarchy-launch-walker -m menus:nomarchyBackgroundSelector --width 800 --minheight 400
}
show_font_menu() {
theme=$(menu "Font" "$(nnomarchy-font-list)" "--width 350" "$(nnomarchy-font-current)")
theme=$(menu "Font" "$(nomarchy-font-list)" "--width 350" "$(nomarchy-font-current)")
if [[ $theme == "CNCLD" || -z $theme ]]; then
back_to show_style_menu
else
nnomarchy-font-set "$theme"
nomarchy-font-set "$theme"
fi
}
@@ -202,16 +202,16 @@ show_setup_menu() {
options="$options\n󰱔 DNS\n Security\n Config"
case $(menu "Setup" "$options") in
*Audio*) nnomarchy-launch-audio ;;
*Wifi*) nnomarchy-launch-wifi ;;
*Bluetooth*) nnomarchy-launch-bluetooth ;;
*Audio*) nomarchy-launch-audio ;;
*Wifi*) nomarchy-launch-wifi ;;
*Bluetooth*) nomarchy-launch-bluetooth ;;
*Power*) show_setup_power_menu ;;
*System*) show_setup_system_menu ;;
*Monitors*) open_in_editor ~/.config/hypr/monitors.conf ;;
*Keybindings*) open_in_editor ~/.config/hypr/bindings.conf ;;
*Input*) open_in_editor ~/.config/hypr/input.conf ;;
*Key\ Remapping*) nnomarchy-setup-makima && open_in_editor "$HOME/.config/makima/AT Translated Set 2 keyboard.toml" && nnomarchy-restart-makima ;;
*DNS*) present_terminal nnomarchy-setup-dns ;;
*Key\ Remapping*) nomarchy-setup-makima && open_in_editor "$HOME/.config/makima/AT Translated Set 2 keyboard.toml" && nomarchy-restart-makima ;;
*DNS*) present_terminal nomarchy-setup-dns ;;
*Security*) show_setup_security_menu ;;
*Config*) show_setup_config_menu ;;
*) show_main_menu ;;
@@ -219,7 +219,7 @@ show_setup_menu() {
}
show_setup_power_menu() {
profile=$(menu "Power Profile" "$(nnomarchy-powerprofiles-list)" "" "$(powerprofilesctl get)")
profile=$(menu "Power Profile" "$(nomarchy-powerprofiles-list)" "" "$(powerprofilesctl get)")
if [[ $profile == "CNCLD" || -z $profile ]]; then
back_to show_setup_menu
@@ -230,8 +230,8 @@ show_setup_power_menu() {
show_setup_security_menu() {
case $(menu "Setup" "󰈷 Fingerprint\n Fido2") in
*Fingerprint*) present_terminal nnomarchy-setup-fingerprint ;;
*Fido2*) present_terminal nnomarchy-setup-fido2 ;;
*Fingerprint*) present_terminal nomarchy-setup-fingerprint ;;
*Fido2*) present_terminal nomarchy-setup-fido2 ;;
*) show_setup_menu ;;
esac
}
@@ -240,13 +240,13 @@ show_setup_config_menu() {
case $(menu "Setup" " Defaults\n Hyprland\n Hypridle\n Hyprlock\n Hyprsunset\n Swayosd\n󰌧 Walker\n󰍜 Waybar\n󰞅 XCompose") in
*Defaults*) open_in_editor ~/.config/uwsm/default ;;
*Hyprland*) open_in_editor ~/.config/hypr/hyprland.conf ;;
*Hypridle*) open_in_editor ~/.config/hypr/hypridle.conf && nnomarchy-restart-hypridle ;;
*Hypridle*) open_in_editor ~/.config/hypr/hypridle.conf && nomarchy-restart-hypridle ;;
*Hyprlock*) open_in_editor ~/.config/hypr/hyprlock.conf ;;
*Hyprsunset*) open_in_editor ~/.config/hypr/hyprsunset.conf && nnomarchy-restart-hyprsunset ;;
*Swayosd*) open_in_editor ~/.config/swayosd/config.toml && nnomarchy-restart-swayosd ;;
*Walker*) open_in_editor ~/.config/walker/config.toml && nnomarchy-restart-walker ;;
*Waybar*) open_in_editor ~/.config/waybar/config.jsonc && nnomarchy-restart-waybar ;;
*XCompose*) open_in_editor ~/.XCompose && nnomarchy-restart-xcompose ;;
*Hyprsunset*) open_in_editor ~/.config/hypr/hyprsunset.conf && nomarchy-restart-hyprsunset ;;
*Swayosd*) open_in_editor ~/.config/swayosd/config.toml && nomarchy-restart-swayosd ;;
*Walker*) open_in_editor ~/.config/walker/config.toml && nomarchy-restart-walker ;;
*Waybar*) open_in_editor ~/.config/waybar/config.jsonc && nomarchy-restart-waybar ;;
*XCompose*) open_in_editor ~/.XCompose && nomarchy-restart-xcompose ;;
*) show_setup_menu ;;
esac
}
@@ -260,16 +260,16 @@ show_setup_system_menu() {
options="$options󰒲 Disable Suspend"
fi
if nnomarchy-hibernation-available; then
if nomarchy-hibernation-available; then
options="$options\n󰤁 Disable Hibernate"
else
options="$options\n󰤁 Enable Hibernate"
fi
case $(menu "System" "$options") in
*Suspend*) nnomarchy-toggle-suspend ;;
*"Enable Hibernate"*) present_terminal nnomarchy-hibernation-setup ;;
*"Disable Hibernate"*) present_terminal nnomarchy-hibernation-remove ;;
*Suspend*) nomarchy-toggle-suspend ;;
*"Enable Hibernate"*) present_terminal nomarchy-hibernation-setup ;;
*"Disable Hibernate"*) present_terminal nomarchy-hibernation-remove ;;
*) show_setup_menu ;;
esac
}
@@ -277,25 +277,25 @@ show_setup_system_menu() {
show_update_menu() {
case $(menu "Update" "  Nnomarchy\n󰸌 Extra Themes\n Process\n󰇅 Hardware\n Firmware\n Password\n Timezone\n Time") in
*Nnomarchy*) present_terminal nnomarchy-update ;;
*Themes*) present_terminal nnomarchy-theme-update ;;
case $(menu "Update" "  Nomarchy\n󰸌 Extra Themes\n Process\n󰇅 Hardware\n Firmware\n Password\n Timezone\n Time") in
*Nomarchy*) present_terminal nomarchy-update ;;
*Themes*) present_terminal nomarchy-theme-update ;;
*Process*) show_update_process_menu ;;
*Hardware*) show_update_hardware_menu ;;
*Firmware*) present_terminal nnomarchy-update-firmware ;;
*Timezone*) present_terminal nnomarchy-tz-select ;;
*Time*) present_terminal nnomarchy-update-time ;;
*Firmware*) present_terminal nomarchy-update-firmware ;;
*Timezone*) present_terminal nomarchy-tz-select ;;
*Time*) present_terminal nomarchy-update-time ;;
*Password*) show_update_password_menu ;;
*) show_main_menu ;;
esac
}
show_update_process_menu() {
case $(menu "Restart" " Hypridle\n Hyprsunset\n Swayosd\n󰌧 Walker\n󰍜 Waybar") in
*Hypridle*) nnomarchy-restart-hypridle ;;
*Hyprsunset*) nnomarchy-restart-hyprsunset ;;
*Swayosd*) nnomarchy-restart-swayosd ;;
*Walker*) nnomarchy-restart-walker ;;
*Waybar*) nnomarchy-restart-waybar ;;
*Hypridle*) nomarchy-restart-hypridle ;;
*Hyprsunset*) nomarchy-restart-hyprsunset ;;
*Swayosd*) nomarchy-restart-swayosd ;;
*Walker*) nomarchy-restart-walker ;;
*Waybar*) nomarchy-restart-waybar ;;
*) show_update_menu ;;
esac
}
@@ -304,39 +304,39 @@ show_update_process_menu() {
show_update_hardware_menu() {
case $(menu "Restart" " Audio\n󱚾 Wi-Fi\n󰂯 Bluetooth") in
*Audio*) present_terminal nnomarchy-restart-pipewire ;;
*Wi-Fi*) present_terminal nnomarchy-restart-wifi ;;
*Bluetooth*) present_terminal nnomarchy-restart-bluetooth ;;
*Audio*) present_terminal nomarchy-restart-pipewire ;;
*Wi-Fi*) present_terminal nomarchy-restart-wifi ;;
*Bluetooth*) present_terminal nomarchy-restart-bluetooth ;;
*) show_update_menu ;;
esac
}
show_update_password_menu() {
case $(menu "Update Password" " Drive Encryption\n User") in
*Drive*) present_terminal nnomarchy-drive-set-password ;;
*Drive*) present_terminal nomarchy-drive-set-password ;;
*User*) present_terminal passwd ;;
*) show_update_menu ;;
esac
}
show_about() {
nnomarchy-launch-about
nomarchy-launch-about
}
show_system_menu() {
local options="󱄄 Screensaver\n Lock"
[[ $NNOMARCHY_TOGGLE_SUSPEND != "false" ]] && options="$options\n󰒲 Suspend"
nnomarchy-hibernation-available && options="$options\n󰤁 Hibernate"
nomarchy-hibernation-available && options="$options\n󰤁 Hibernate"
options="$options\n󰍃 Logout\n󰜉 Restart\n󰐥 Shutdown"
case $(menu "System" "$options") in
*Screensaver*) nnomarchy-launch-screensaver force ;;
*Lock*) nnomarchy-lock-screen ;;
*Screensaver*) nomarchy-launch-screensaver force ;;
*Lock*) nomarchy-lock-screen ;;
*Suspend*) systemctl suspend ;;
*Hibernate*) systemctl hibernate ;;
*Logout*) nnomarchy-system-logout ;;
*Restart*) nnomarchy-system-reboot ;;
*Shutdown*) nnomarchy-system-shutdown ;;
*Logout*) nomarchy-system-logout ;;
*Restart*) nomarchy-system-reboot ;;
*Shutdown*) nomarchy-system-shutdown ;;
*) back_to show_main_menu ;;
esac
}
@@ -366,7 +366,7 @@ go_to_menu() {
}
# Allow user extensions and overrides
USER_EXTENSIONS="$HOME/.config/nnomarchy/extensions/menu.sh"
USER_EXTENSIONS="$HOME/.config/nomarchy/extensions/menu.sh"
[[ -f $USER_EXTENSIONS ]] && source "$USER_EXTENSIONS"
toggle_existing_menu

View File

@@ -79,7 +79,7 @@ parse_keycodes() {
# Fetch dynamic keybindings from Hyprland
#
# Also do some pre-processing:
# - Remove standard Nnomarchy bin path prefix
# - Remove standard Nomarchy bin path prefix
# - Remove uwsm prefix
# - Map numeric modifier key mask to a textual rendition
# - Output comma-separated values that the parser can understand
@@ -88,7 +88,7 @@ dynamic_bindings() {
jq -r '.[] | {modmask, key, keycode, description, dispatcher, arg} | "\(.modmask),\(.key)@\(.keycode),\(.description),\(.dispatcher),\(.arg)"' |
sed -r \
-e 's/null//' \
-e 's,~/.local/share/nnomarchy/bin/,,' \
-e 's,~/.local/share/nomarchy/bin/,,' \
-e 's,uwsm app -- ,,' \
-e 's,uwsm-app -- ,,' \
-e 's/@0//' \
@@ -172,7 +172,7 @@ prioritize_entries() {
if (match(line, /Browser/) && !match(line, /Browser[[:space:]]*\(/) && !match(line, /SUPER SHIFT.*\+.*B.*→.*Browser/)) prio = 2
if (match(line, /File manager/) && !match(line, /File manager \(cwd\)/)) prio = 3
if (match(line, /Launch apps/)) prio = 4
if (match(line, /Nnomarchy menu/)) prio = 5
if (match(line, /Nomarchy menu/)) prio = 5
if (match(line, /System menu/)) prio = 6
if (match(line, /Theme menu/)) prio = 7
if (match(line, /Full screen/)) prio = 8

View File

@@ -3,7 +3,7 @@
# Dismiss a mako notification on the basis of its summary. Used by the first-run notifications to dismiss them after clicking for action.
if (($# == 0)); then
echo "Usage: nnomarchy-notification-dismiss <summary>"
echo "Usage: nomarchy-notification-dismiss <summary>"
exit 1
fi

View File

@@ -1,13 +1,13 @@
#!/bin/bash
# Install an npx wrapper for a given npm package.
# Usage: nnomarchy-npx-install <package> [command-name]
# Usage: nomarchy-npx-install <package> [command-name]
#
# If command-name is omitted, it defaults to the package name.
# Example: nnomarchy-npx-install opencode-ai opencode
# Example: nomarchy-npx-install opencode-ai opencode
if [[ -z $1 ]]; then
echo "Usage: nnomarchy-npx-install <package> [command-name]"
echo "Usage: nomarchy-npx-install <package> [command-name]"
exit 1
fi

View File

@@ -1,21 +1,21 @@
#!/usr/bin/env bash
# Nnomarchy on-boot initialization script.
# Nomarchy on-boot initialization script.
# Automatically detects the hardware, applies necessary runtime tweaks,
# and sets the correct screen resolution/scaling.
# 1. Automatically configure optimal screen resolution and scaling
nnomarchy-hyprland-monitor-scaling-cycle >/dev/null 2>&1
nomarchy-hyprland-monitor-scaling-cycle >/dev/null 2>&1
# 2. Hardware-specific runtime tweaks
if nnomarchy-hw-match "Laptop 16"; then
if nomarchy-hw-match "Laptop 16"; then
# Framework 16 specific tweaks
nnomarchy-theme-set-keyboard-f16 >/dev/null 2>&1
nomarchy-theme-set-keyboard-f16 >/dev/null 2>&1
fi
if nnomarchy-hw-asus-rog; then
if nomarchy-hw-asus-rog; then
# Asus ROG specific tweaks
nnomarchy-theme-set-keyboard-asus-rog >/dev/null 2>&1
nomarchy-theme-set-keyboard-asus-rog >/dev/null 2>&1
fi
# 3. Declarative hardware configuration check (nixos-hardware)

View File

@@ -1,5 +1,5 @@
#!/bin/bash
# Overwrite the user config for fastfetch with the Nnomarchy default.
# Overwrite the user config for fastfetch with the Nomarchy default.
nnomarchy-refresh-config fastfetch/config.jsonc
nomarchy-refresh-config fastfetch/config.jsonc

View File

@@ -3,20 +3,20 @@
set -e
COMMAND="$1"
NOMARCHY_PATH=${NOMARCHY_PATH:-$HOME/.local/share/nnomarchy}
NOMARCHY_PATH=${NOMARCHY_PATH:-$HOME/.local/share/nomarchy}
if [[ -z $COMMAND ]]; then
echo "Usage: nnomarchy-snapshot <create|restore>" >&2
echo "Usage: nomarchy-snapshot <create|restore>" >&2
exit 1
fi
if ! command -v snapper &>/dev/null; then
exit 127 # nnomarchy-update can use this to just ignore if snapper is not available
exit 127 # nomarchy-update can use this to just ignore if snapper is not available
fi
case "$COMMAND" in
create)
DESC="$(nnomarchy-version)"
DESC="$(nomarchy-version)"
echo -e "\e[32mCreate system snapshot\e[0m"

View File

@@ -1,24 +1,24 @@
#!/bin/bash
# Manage persistent runtime state files for Nnomarchy indicators.
# Usage: nnomarchy-state <set|clear> <state-name-or-pattern>
# Manage persistent runtime state files for Nomarchy indicators.
# Usage: nomarchy-state <set|clear> <state-name-or-pattern>
# Used to track whether things like reboot, restart, etc are required.
# DO NOT use this for configuration toggles (suspend, screensaver, etc).
# Use declarative Nnomarchy NixOS home-manager options for those instead.
# Use declarative Nomarchy NixOS home-manager options for those instead.
STATE_DIR="$HOME/.local/state/nnomarchy"
STATE_DIR="$HOME/.local/state/nomarchy"
mkdir -p "$STATE_DIR"
COMMAND="$1"
STATE_NAME="$2"
if [[ -z $COMMAND ]]; then
echo "Usage: nnomarchy-state <set|clear> <state-name-or-pattern>"
echo "Usage: nomarchy-state <set|clear> <state-name-or-pattern>"
exit 1
fi
if [[ -z $STATE_NAME ]]; then
echo "Usage: nnomarchy-state $COMMAND <state-name>"
echo "Usage: nomarchy-state $COMMAND <state-name>"
exit 1
fi

View File

@@ -1,11 +1,11 @@
#!/usr/bin/env bash
# nnomarchy-sync: Automate backing up and restoring Nnomarchy declarative configurations and dynamic state.
# nomarchy-sync: Automate backing up and restoring Nomarchy declarative configurations and dynamic state.
set -e
if [[ -z $1 ]]; then
echo "Usage: nnomarchy-sync <push|pull> [repo-url]"
echo "Usage: nomarchy-sync <push|pull> [repo-url]"
echo " push: Backup current state to the configured repository."
echo " pull: Restore state from the configured repository and apply updates."
exit 1
@@ -18,7 +18,7 @@ STATE_DIR="$HOME/.config/home-manager"
CONFIG_DIR="/etc/nixos"
# Identify the target repo directory (we use a local dot-folder to stage things)
SYNC_DIR="$HOME/.local/share/nnomarchy-sync"
SYNC_DIR="$HOME/.local/share/nomarchy-sync"
mkdir -p "$SYNC_DIR"
cd "$SYNC_DIR"
@@ -26,14 +26,14 @@ cd "$SYNC_DIR"
if [ ! -d ".git" ]; then
if [[ -z $REPO_URL ]]; then
echo "Error: No Git repository configured. Please provide a repo-url for the first run:"
echo "Example: nnomarchy-sync push git@github.com:username/nnomarchy-backup.git"
echo "Example: nomarchy-sync push git@github.com:username/nomarchy-backup.git"
exit 1
fi
git init
git remote add origin "$REPO_URL"
# Basic configuration for automated commits
git config user.name "Nnomarchy Sync"
git config user.email "sync@nnomarchy.local"
git config user.name "Nomarchy Sync"
git config user.email "sync@nomarchy.local"
fi
if [[ "$COMMAND" == "push" ]]; then