feat(system): comprehensive branding, styling, and system feature update
- Relocate themes to assets/themes/ and update all references. - Implement custom SDDM theme and Plymouth theme enhancements. - Add themed templates for Alacritty, Hyprland, Waybar, and other apps. - Introduce Makima key remapper module and configuration. - Add Voxtype and Walker configurations. - Implement systemd power management and timeout optimizations. - Add Nautilus-python extensions for LocalSend. - Update branding assets and ASCII art integration.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns the name of the current monospace font being used by extracting it from the Waybar stylesheet.
|
||||
# This can be changed using nomarchy-font-set.
|
||||
# This can be changed using nnomarchy-font-set.
|
||||
|
||||
grep -oP 'font-family:\s*["'\'']?\K[^;"'\'']+' ~/.config/waybar/style.css | head -n1
|
||||
@@ -1,5 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns a list of all the monospace fonts available on the system that can be set using nomarchy-font-set.
|
||||
# Returns a list of all the monospace fonts available on the system that can be set using nnomarchy-font-set.
|
||||
|
||||
fc-list :spacing=100 -f "%{family[0]}\n" | grep -v -i -E 'emoji|signwriting|nomarchy' | sort -u
|
||||
fc-list :spacing=100 -f "%{family[0]}\n" | grep -v -i -E 'emoji|signwriting|nnomarchy' | sort -u
|
||||
@@ -1,12 +1,12 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Set the system-wide monospace font that should be used by the terminal, hyprlock, waybar, swayosd, etc.
|
||||
# Declarative version for Nomarchy NixOS.
|
||||
# Declarative version for Nnomarchy NixOS.
|
||||
|
||||
font_name="$1"
|
||||
|
||||
if [[ -z $font_name ]]; then
|
||||
echo "Usage: nomarchy-font-set <font-name>"
|
||||
echo "Usage: nnomarchy-font-set <font-name>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -31,7 +31,7 @@ if fc-list | grep -iq "$font_name"; then
|
||||
notify-send -u low " You must restart Ghostty to see font change"
|
||||
fi
|
||||
|
||||
nomarchy-hook font-set "$font_name"
|
||||
nnomarchy-hook font-set "$font_name"
|
||||
else
|
||||
echo "Font '$font_name' not found."
|
||||
exit 1
|
||||
@@ -1,10 +1,10 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Display the Nomarchy logo in the terminal using green color.
|
||||
# Display the Nnomarchy logo in the terminal using green color.
|
||||
# Used by various presentation scripts to show branding.
|
||||
|
||||
clear
|
||||
echo -e "\033[32m"
|
||||
cat < ~/.config/nomarchy/branding/logo.txt
|
||||
cat < ~/.config/nnomarchy/branding/logo.txt
|
||||
echo -e "\033[0m"
|
||||
echo
|
||||
7
bin/appearance/nomarchy-theme-bg-install
Executable file
7
bin/appearance/nomarchy-theme-bg-install
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
CURRENT_THEME_NAME=$(cat "$HOME/.config/nnomarchy/current/theme.name")
|
||||
THEME_USER_BACKGROUNDS="$HOME/.config/nnomarchy/backgrounds/$CURRENT_THEME_NAME"
|
||||
|
||||
mkdir -p "$THEME_USER_BACKGROUNDS"
|
||||
nautilus "$THEME_USER_BACKGROUNDS"
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Cycles through the background images available for the current theme.
|
||||
# Declarative + Hybrid (instant swww) for Nomarchy NixOS.
|
||||
# Declarative + Hybrid (instant swww) for Nnomarchy NixOS.
|
||||
|
||||
STATE_DIR="$HOME/.config/home-manager"
|
||||
STATE_FILE="$STATE_DIR/state.json"
|
||||
@@ -11,10 +11,10 @@ mkdir -p "$STATE_DIR"
|
||||
THEME_NAME=$(jq -r '.theme // "nord"' "$STATE_FILE")
|
||||
|
||||
# Resolve themes directory (Built-in from Nix store via Home Manager, or user extra)
|
||||
if [ -d "$HOME/.config/nomarchy/themes/$THEME_NAME" ]; then
|
||||
THEMES_DIR="$HOME/.config/nomarchy/themes"
|
||||
if [ -d "$HOME/.config/nnomarchy/themes/$THEME_NAME" ]; then
|
||||
THEMES_DIR="$HOME/.config/nnomarchy/themes"
|
||||
else
|
||||
THEMES_DIR="$HOME/.local/share/nomarchy/themes"
|
||||
THEMES_DIR="$HOME/.local/share/nnomarchy/themes"
|
||||
fi
|
||||
|
||||
BG_DIR="$THEMES_DIR/$THEME_NAME/backgrounds"
|
||||
@@ -3,12 +3,12 @@
|
||||
# Sets the specified image as the current background
|
||||
|
||||
if [[ -z $1 ]]; then
|
||||
echo "Usage: nomarchy-theme-bg-set <path-to-image>" >&2
|
||||
echo "Usage: nnomarchy-theme-bg-set <path-to-image>" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
BACKGROUND="$1"
|
||||
CURRENT_BACKGROUND_LINK="$HOME/.config/nomarchy/current/background"
|
||||
CURRENT_BACKGROUND_LINK="$HOME/.config/nnomarchy/current/background"
|
||||
|
||||
# Create symlink to the new background
|
||||
ln -nsf "$BACKGROUND" "$CURRENT_BACKGROUND_LINK"
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
THEME_NAME_PATH="$HOME/.config/nomarchy/current/theme.name"
|
||||
THEME_NAME_PATH="$HOME/.config/nnomarchy/current/theme.name"
|
||||
|
||||
if [[ -f $THEME_NAME_PATH ]]; then
|
||||
cat $THEME_NAME_PATH | sed -E 's/(^|-)([a-z])/\1\u\2/g; s/-/ /g'
|
||||
33
bin/appearance/nomarchy-theme-install
Executable file
33
bin/appearance/nomarchy-theme-install
Executable file
@@ -0,0 +1,33 @@
|
||||
#!/bin/bash
|
||||
|
||||
# nnomarchy-theme-install: Install a new theme from a git repo for Nnomarchy
|
||||
# Usage: nnomarchy-theme-install <git-repo-url>
|
||||
|
||||
if [[ -z $1 ]]; then
|
||||
echo -e "\e[32mSee https://manuals.omamix.org/2/the-nnomarchy-manual/90/extra-themes\n\e[0m"
|
||||
REPO_URL=$(gum input --placeholder="Git repo URL for theme" --header="")
|
||||
else
|
||||
REPO_URL="$1"
|
||||
fi
|
||||
|
||||
if [[ -z $REPO_URL ]]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
THEMES_DIR="$HOME/.config/nnomarchy/themes"
|
||||
THEME_NAME=$(basename "$REPO_URL" .git | sed -E 's/^nnomarchy-//; s/-theme$//')
|
||||
THEME_PATH="$THEMES_DIR/$THEME_NAME"
|
||||
|
||||
# Remove existing theme if present
|
||||
if [[ -d $THEME_PATH ]]; then
|
||||
rm -rf "$THEME_PATH"
|
||||
fi
|
||||
|
||||
# Clone the repo directly to ~/.config/nnomarchy/themes
|
||||
if ! git clone "$REPO_URL" "$THEME_PATH"; then
|
||||
echo "Error: Failed to clone theme repo."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Apply the new theme with nnomarchy-theme-set
|
||||
nnomarchy-theme-set $THEME_NAME
|
||||
8
bin/appearance/nomarchy-theme-list
Executable file
8
bin/appearance/nomarchy-theme-list
Executable file
@@ -0,0 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
{
|
||||
find ~/.config/nnomarchy/themes/ -mindepth 1 -maxdepth 1 \( -type d -o -type l \) -printf '%f\n'
|
||||
find "$NOMARCHY_PATH/assets/themes/" -mindepth 1 -maxdepth 1 -type d -printf '%f\n'
|
||||
} | sort -u | while read -r name; do
|
||||
echo "$name" | sed -E 's/(^|-)([a-z])/\1\u\2/g; s/-/ /g'
|
||||
done
|
||||
9
bin/appearance/nomarchy-theme-refresh
Executable file
9
bin/appearance/nomarchy-theme-refresh
Executable file
@@ -0,0 +1,9 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Refresh the current theme from its templates.
|
||||
|
||||
THEME_NAME_PATH="$HOME/.config/nnomarchy/current/theme.name"
|
||||
|
||||
if [[ -f $THEME_NAME_PATH ]]; then
|
||||
nnomarchy-theme-set "$(cat $THEME_NAME_PATH)"
|
||||
fi
|
||||
@@ -1,10 +1,10 @@
|
||||
#!/bin/bash
|
||||
|
||||
# nomarchy-theme-remove: Remove a theme from Nomarchy by name
|
||||
# Usage: nomarchy-theme-remove <theme-name>
|
||||
# nnomarchy-theme-remove: Remove a theme from Nnomarchy by name
|
||||
# Usage: nnomarchy-theme-remove <theme-name>
|
||||
|
||||
if [[ -z $1 ]]; then
|
||||
mapfile -t extra_themes < <(find ~/.config/nomarchy/themes -mindepth 1 -maxdepth 1 -type d ! -xtype l -printf '%f\n')
|
||||
mapfile -t extra_themes < <(find ~/.config/nnomarchy/themes -mindepth 1 -maxdepth 1 -type d ! -xtype l -printf '%f\n')
|
||||
|
||||
if (( ${#extra_themes[@]} > 0 )); then
|
||||
THEME_NAME=$(printf '%s\n' "${extra_themes[@]}" | sort | gum choose --header="Remove extra theme")
|
||||
@@ -16,8 +16,8 @@ else
|
||||
THEME_NAME="$1"
|
||||
fi
|
||||
|
||||
THEMES_DIR="$HOME/.config/nomarchy/themes"
|
||||
CURRENT_DIR="$HOME/.config/nomarchy/current"
|
||||
THEMES_DIR="$HOME/.config/nnomarchy/themes"
|
||||
CURRENT_DIR="$HOME/.config/nnomarchy/current"
|
||||
THEME_PATH="$THEMES_DIR/$THEME_NAME"
|
||||
|
||||
# Ensure a theme was set
|
||||
@@ -1,12 +1,12 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Set the system theme declaratively.
|
||||
# Usage: nomarchy-theme-set <theme-name>
|
||||
# Usage: nnomarchy-theme-set <theme-name>
|
||||
|
||||
THEME_NAME="$1"
|
||||
|
||||
if [[ -z $THEME_NAME ]]; then
|
||||
echo "Usage: nomarchy-theme-set <theme-name>"
|
||||
echo "Usage: nnomarchy-theme-set <theme-name>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -14,10 +14,10 @@ STATE_DIR="$HOME/.config/home-manager"
|
||||
STATE_FILE="$STATE_DIR/state.json"
|
||||
|
||||
# Resolve themes directory (Built-in from Nix store via Home Manager, or user extra)
|
||||
if [ -d "$HOME/.config/nomarchy/themes/$THEME_NAME" ]; then
|
||||
THEMES_DIR="$HOME/.config/nomarchy/themes"
|
||||
if [ -d "$HOME/.config/nnomarchy/themes/$THEME_NAME" ]; then
|
||||
THEMES_DIR="$HOME/.config/nnomarchy/themes"
|
||||
else
|
||||
THEMES_DIR="$HOME/.local/share/nomarchy/themes"
|
||||
THEMES_DIR="$HOME/.local/share/nnomarchy/themes"
|
||||
fi
|
||||
|
||||
mkdir -p "$STATE_DIR"
|
||||
@@ -26,7 +26,7 @@ mkdir -p "$STATE_DIR"
|
||||
if [ ! -d "$THEMES_DIR/$THEME_NAME" ] && ! [[ "$THEME_NAME" == "nord" ]]; then
|
||||
echo "Theme '$THEME_NAME' not found in $THEMES_DIR"
|
||||
# Check if it exists in the palettes file
|
||||
# (Assuming nomarchy-palettes.nix is imported in Nix)
|
||||
# (Assuming nnomarchy-palettes.nix is imported in Nix)
|
||||
fi
|
||||
|
||||
TMP_JSON=$(mktemp)
|
||||
@@ -49,9 +49,9 @@ if [ -d "$BG_DIR" ]; then
|
||||
fi
|
||||
|
||||
echo "Theme set to $THEME_NAME. Applying changes with env-update..."
|
||||
rm -rf "$HOME/.config/nomarchy/current/theme"
|
||||
rm -rf "$HOME/.config/nnomarchy/current/theme"
|
||||
env-update
|
||||
|
||||
nomarchy-theme-set-templates
|
||||
nnomarchy-theme-set-templates
|
||||
|
||||
nomarchy-hook theme-set "$THEME_NAME"
|
||||
nnomarchy-hook theme-set "$THEME_NAME"
|
||||
4
bin/appearance/nomarchy-theme-set-keyboard
Executable file
4
bin/appearance/nomarchy-theme-set-keyboard
Executable file
@@ -0,0 +1,4 @@
|
||||
#!/bin/bash
|
||||
|
||||
nnomarchy-theme-set-keyboard-asus-rog
|
||||
nnomarchy-theme-set-keyboard-f16
|
||||
7
bin/appearance/nomarchy-theme-set-keyboard-asus-rog
Executable file
7
bin/appearance/nomarchy-theme-set-keyboard-asus-rog
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
ASUSCTL_THEME=~/.config/nnomarchy/current/theme/keyboard.rgb
|
||||
|
||||
if nnomarchy-cmd-present asusctl; then
|
||||
asusctl aura effect static -c $(sed 's/^#//' $ASUSCTL_THEME)
|
||||
fi
|
||||
@@ -1,8 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
FRAMEWORK16_THEME=~/.config/nomarchy/current/theme/keyboard.rgb
|
||||
FRAMEWORK16_THEME=~/.config/nnomarchy/current/theme/keyboard.rgb
|
||||
|
||||
if nomarchy-cmd-present qmk_hid && [[ -f $FRAMEWORK16_THEME ]]; then
|
||||
if nnomarchy-cmd-present qmk_hid && [[ -f $FRAMEWORK16_THEME ]]; then
|
||||
hex=$(cat "$FRAMEWORK16_THEME")
|
||||
hex="${hex#\#}"
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Sync Nomarchy theme to all Obsidian vaults
|
||||
# Sync Nnomarchy theme to all Obsidian vaults
|
||||
|
||||
CURRENT_THEME_DIR="$HOME/.config/nomarchy/current/theme"
|
||||
CURRENT_THEME_DIR="$HOME/.config/nnomarchy/current/theme"
|
||||
|
||||
[[ -f $CURRENT_THEME_DIR/obsidian.css ]] || exit 0
|
||||
|
||||
jq -r '.vaults | values[].path' ~/.config/obsidian/obsidian.json 2>/dev/null | while read -r vault_path; do
|
||||
[[ -d $vault_path/.obsidian ]] || continue
|
||||
|
||||
theme_dir="$vault_path/.obsidian/themes/Nomarchy"
|
||||
theme_dir="$vault_path/.obsidian/themes/Nnomarchy"
|
||||
mkdir -p "$theme_dir"
|
||||
|
||||
[[ -f $theme_dir/manifest.json ]] || cat >"$theme_dir/manifest.json" <<'EOF'
|
||||
{
|
||||
"name": "Nomarchy",
|
||||
"name": "Nnomarchy",
|
||||
"version": "1.0.0",
|
||||
"minAppVersion": "0.16.0",
|
||||
"description": "Automatically syncs with your current Nomarchy system theme colors and fonts",
|
||||
"author": "Nomarchy",
|
||||
"authorUrl": "https://nomarchy.org"
|
||||
"description": "Automatically syncs with your current Nnomarchy system theme colors and fonts",
|
||||
"author": "Nnomarchy",
|
||||
"authorUrl": "https://nnomarchy.org"
|
||||
}
|
||||
EOF
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
TEMPLATES_DIR="$OMARCHY_PATH/default/themed"
|
||||
USER_TEMPLATES_DIR="$HOME/.config/nomarchy/themed"
|
||||
NEXT_THEME_DIR="$HOME/.config/nomarchy/current/theme"
|
||||
TEMPLATES_DIR="$NOMARCHY_PATH/assets/themed"
|
||||
USER_TEMPLATES_DIR="$HOME/.config/nnomarchy/themed"
|
||||
NEXT_THEME_DIR="$HOME/.config/nnomarchy/current/theme"
|
||||
COLORS_FILE="$NEXT_THEME_DIR/colors.toml"
|
||||
|
||||
# Convert hex color to decimal RGB (e.g., "#1e1e2e" -> "30,30,46")
|
||||
@@ -1,14 +1,14 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Sync Nomarchy theme to VS Code, VSCodium, and Cursor
|
||||
# Sync Nnomarchy theme to VS Code, VSCodium, and Cursor
|
||||
|
||||
VS_CODE_THEME="$HOME/.config/nomarchy/current/theme/vscode.json"
|
||||
VS_CODE_THEME="$HOME/.config/nnomarchy/current/theme/vscode.json"
|
||||
|
||||
set_theme() {
|
||||
local editor_cmd="$1"
|
||||
local settings_path="$2"
|
||||
|
||||
nomarchy-cmd-present "$editor_cmd" && [[ $NOMARCHY_TOGGLE_SKIP_VSCODE_THEME != "true" ]] || return 0
|
||||
nnomarchy-cmd-present "$editor_cmd" && [[ $NNOMARCHY_TOGGLE_SKIP_VSCODE_THEME != "true" ]] || return 0
|
||||
|
||||
if [[ -f $VS_CODE_THEME ]]; then
|
||||
theme_name=$(jq -r '.name' "$VS_CODE_THEME")
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
for dir in ~/.config/nomarchy/themes/*/; do
|
||||
for dir in ~/.config/nnomarchy/themes/*/; do
|
||||
if [[ -d $dir ]] && [[ ! -L ${dir%/} ]] && [[ -d $dir/.git ]]; then
|
||||
echo "Updating: $(basename "$dir")"
|
||||
git -C "$dir" pull
|
||||
@@ -9,7 +9,7 @@ mkdir -p "$(dirname "$STATE_FILE")"
|
||||
# Initialize if doesn't exist
|
||||
[[ ! -f $STATE_FILE ]] && echo "{}" > "$STATE_FILE"
|
||||
|
||||
if [[ $NOMARCHY_TOGGLE_NIGHTLIGHT == "false" ]]; then
|
||||
if [[ $NNOMARCHY_TOGGLE_NIGHTLIGHT == "false" ]]; then
|
||||
NEW_VALUE="true"
|
||||
hyprctl dispatch exec hyprsunset --temperature 4000
|
||||
notify-send -u low " Nightlight enabled"
|
||||
@@ -2,4 +2,4 @@
|
||||
|
||||
# Launch the fastfetch TUI that gives information about the current system.
|
||||
|
||||
exec nomarchy-launch-or-focus-tui "bash -c 'fastfetch; read -n 1 -s'"
|
||||
exec nnomarchy-launch-or-focus-tui "bash -c 'fastfetch; read -n 1 -s'"
|
||||
5
bin/apps/nomarchy-launch-audio
Executable file
5
bin/apps/nomarchy-launch-audio
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch the Nnomarchy audio controls TUI (provided by wiremix).
|
||||
|
||||
nnomarchy-launch-or-focus-tui wiremix
|
||||
7
bin/apps/nomarchy-launch-bluetooth
Executable file
7
bin/apps/nomarchy-launch-bluetooth
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch the Nnomarchy bluetooth controls TUI (provided by bluetui).
|
||||
# Also attempts to unblock bluetooth service if rfkill had blocked it.
|
||||
|
||||
rfkill unblock bluetooth
|
||||
exec nnomarchy-launch-or-focus-tui bluetui
|
||||
@@ -3,11 +3,11 @@
|
||||
# Launch the default editor as determined by $EDITOR (set via ~/.config/uwsm/default) (or nvim if missing).
|
||||
# Starts suitable editors in a terminal window and otherwise as a regular application.
|
||||
|
||||
nomarchy-cmd-present "$EDITOR" || EDITOR=nvim
|
||||
nnomarchy-cmd-present "$EDITOR" || EDITOR=nvim
|
||||
|
||||
case "$EDITOR" in
|
||||
nvim | vim | nano | micro | hx | helix | fresh)
|
||||
exec nomarchy-launch-tui "$EDITOR" "$@"
|
||||
exec nnomarchy-launch-tui "$EDITOR" "$@"
|
||||
;;
|
||||
*)
|
||||
exec setsid uwsm-app -- "$EDITOR" "$@"
|
||||
7
bin/apps/nomarchy-launch-floating-terminal-with-presentation
Executable file
7
bin/apps/nomarchy-launch-floating-terminal-with-presentation
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch a floating terminal with the Nnomarchy logo presentation, then execute the command passed in, and finally end with the nnomarchy-show-done presentation.
|
||||
# Used by actions such as Update System.
|
||||
|
||||
cmd="$*"
|
||||
exec setsid uwsm-app -- xdg-terminal-exec --app-id=org.nnomarchy.terminal --title=Nnomarchy -e bash -c "nnomarchy-show-logo; $cmd; if (( \$? != 130 )); then nnomarchy-show-done; fi"
|
||||
@@ -4,7 +4,7 @@
|
||||
# Use by some default bindings, like the one for Spotify, to ensure there is only one instance of the application open.
|
||||
|
||||
if (($# == 0)); then
|
||||
echo "Usage: nomarchy-launch-or-focus [window-pattern] [launch-command]"
|
||||
echo "Usage: nnomarchy-launch-or-focus [window-pattern] [launch-command]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
9
bin/apps/nomarchy-launch-or-focus-tui
Executable file
9
bin/apps/nomarchy-launch-or-focus-tui
Executable file
@@ -0,0 +1,9 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch or focus on a given TUI identified by the passed in as the command.
|
||||
# Use by commands like nnomarchy-launch-wifi to ensure there is only one wifi configuration screen open.
|
||||
|
||||
APP_ID="org.nnomarchy.$(basename "$1")"
|
||||
LAUNCH_COMMAND="nnomarchy-launch-tui $@"
|
||||
|
||||
exec nnomarchy-launch-or-focus "$APP_ID" "$LAUNCH_COMMAND"
|
||||
@@ -4,12 +4,12 @@
|
||||
# Use by some default bindings, like the one for WhatsApp, to ensure there is only one instance of the application open.
|
||||
|
||||
if (($# == 0)); then
|
||||
echo "Usage: nomarchy-launch-or-focus-webapp [window-pattern] [url-and-flags...]"
|
||||
echo "Usage: nnomarchy-launch-or-focus-webapp [window-pattern] [url-and-flags...]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
WINDOW_PATTERN="$1"
|
||||
shift
|
||||
LAUNCH_COMMAND="nomarchy-launch-webapp $@"
|
||||
LAUNCH_COMMAND="nnomarchy-launch-webapp $@"
|
||||
|
||||
exec nomarchy-launch-or-focus "$WINDOW_PATTERN" "$LAUNCH_COMMAND"
|
||||
exec nnomarchy-launch-or-focus "$WINDOW_PATTERN" "$LAUNCH_COMMAND"
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch the Nomarchy screensaver in the default terminal on the system with the correct font configuration.
|
||||
# Launch the Nnomarchy screensaver in the default terminal on the system with the correct font configuration.
|
||||
|
||||
# Exit early if we don't have the tte show
|
||||
if ! command -v tte &>/dev/null; then
|
||||
@@ -8,11 +8,11 @@ if ! command -v tte &>/dev/null; then
|
||||
fi
|
||||
|
||||
# Exit early if screensave is already running
|
||||
pgrep -f org.nomarchy.screensaver && exit 0
|
||||
pgrep -f org.nnomarchy.screensaver && exit 0
|
||||
|
||||
# Allow screensaver to be turned off but also force started
|
||||
# Skip if screensaver is disabled in configuration
|
||||
if [[ $NOMARCHY_TOGGLE_SCREENSAVER == "false" ]] && [[ $1 != "force" ]]; then
|
||||
if [[ $NNOMARCHY_TOGGLE_SCREENSAVER == "false" ]] && [[ $1 != "force" ]]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
@@ -29,23 +29,23 @@ for m in $(hyprctl monitors -j | jq -r '.[] | .name'); do
|
||||
case $terminal in
|
||||
*Alacritty*)
|
||||
hyprctl dispatch exec -- \
|
||||
alacritty --class=org.nomarchy.screensaver \
|
||||
--config-file ~/.local/share/nomarchy/default/alacritty/screensaver.toml \
|
||||
-e nomarchy-cmd-screensaver
|
||||
alacritty --class=org.nnomarchy.screensaver \
|
||||
--config-file ~/.local/share/nnomarchy/default/alacritty/screensaver.toml \
|
||||
-e nnomarchy-cmd-screensaver
|
||||
;;
|
||||
*ghostty*)
|
||||
hyprctl dispatch exec -- \
|
||||
ghostty --class=org.nomarchy.screensaver \
|
||||
--config-file=~/.local/share/nomarchy/default/ghostty/screensaver \
|
||||
ghostty --class=org.nnomarchy.screensaver \
|
||||
--config-file=~/.local/share/nnomarchy/default/ghostty/screensaver \
|
||||
--font-size=18 \
|
||||
-e nomarchy-cmd-screensaver
|
||||
-e nnomarchy-cmd-screensaver
|
||||
;;
|
||||
*kitty*)
|
||||
hyprctl dispatch exec -- \
|
||||
kitty --class=org.nomarchy.screensaver \
|
||||
kitty --class=org.nnomarchy.screensaver \
|
||||
--override font_size=18 \
|
||||
--override window_padding_width=0 \
|
||||
-e nomarchy-cmd-screensaver
|
||||
-e nnomarchy-cmd-screensaver
|
||||
;;
|
||||
*)
|
||||
notify-send -u low "✋ Screensaver only runs in Alacritty, Ghostty, or Kitty"
|
||||
5
bin/apps/nomarchy-launch-tui
Executable file
5
bin/apps/nomarchy-launch-tui
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch the TUI command passed in as an argument in the default terminal with an org.nnomarchy.COMMAND app id for styling.
|
||||
|
||||
exec setsid uwsm-app -- xdg-terminal-exec --app-id=org.nnomarchy.$(basename $1) -e "$1" "${@:2}"
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch the Nomarchy wifi controls (provided by the Impala TUI).
|
||||
# Launch the Nnomarchy wifi controls (provided by the Impala TUI).
|
||||
# Attempts to unblock the wifi service first in case it should be been blocked.
|
||||
|
||||
rfkill unblock wifi
|
||||
nomarchy-launch-or-focus-tui impala
|
||||
nnomarchy-launch-or-focus-tui impala
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Restart an application by killing it and relaunching via uwsm.
|
||||
# Usage: nomarchy-restart-app <application-name> [application-args...]
|
||||
# Usage: nnomarchy-restart-app <application-name> [application-args...]
|
||||
|
||||
pkill -x $1
|
||||
setsid uwsm-app -- "$@" >/dev/null 2>&1 &
|
||||
5
bin/apps/nomarchy-restart-btop
Executable file
5
bin/apps/nomarchy-restart-btop
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Reload btop configuration (used by the Nnomarchy theme switching).
|
||||
|
||||
pkill -SIGUSR2 btop
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Reload opencode configuration (used by the Nomarchy theme switching).
|
||||
# Reload opencode configuration (used by the Nnomarchy theme switching).
|
||||
|
||||
if pgrep -x opencode >/dev/null; then
|
||||
killall -SIGUSR2 opencode
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Remove all TUIs installed via nomarchy-tui-install.
|
||||
# Remove all TUIs installed via nnomarchy-tui-install.
|
||||
# Identifies TUIs by their Exec pattern (xdg-terminal-exec --app-id=TUI.).
|
||||
|
||||
set -e
|
||||
@@ -3,4 +3,4 @@ set -e
|
||||
|
||||
# Used by Voxtype waybar module to open config on right click
|
||||
|
||||
exec nomarchy-launch-editor ~/.config/voxtype/config.toml
|
||||
exec nnomarchy-launch-editor ~/.config/voxtype/config.toml
|
||||
@@ -4,18 +4,18 @@ set -e
|
||||
# Install voxtype and configure it for use.
|
||||
|
||||
if gum confirm "Install Voxtype + AI model (~150MB) to enable dictation?"; then
|
||||
nomarchy-pkg-add wtype voxtype-bin
|
||||
nnomarchy-pkg-add wtype voxtype-bin
|
||||
|
||||
# Setup voxtype
|
||||
mkdir -p ~/.config/voxtype
|
||||
cp $OMARCHY_PATH/default/voxtype/config.toml ~/.config/voxtype/
|
||||
cp ~/.config/nomarchy/default/voxtype/config.toml ~/.config/voxtype/
|
||||
|
||||
voxtype setup --download --no-post-install
|
||||
if nomarchy-hw-vulkan; then
|
||||
if nnomarchy-hw-vulkan; then
|
||||
voxtype setup gpu --enable || true
|
||||
fi
|
||||
voxtype setup systemd
|
||||
|
||||
nomarchy-restart-waybar
|
||||
nnomarchy-restart-waybar
|
||||
notify-send " Voxtype Dictation Ready" "Press Super + Ctrl + X to toggle dictation.\nEdit ~/.config/voxtype/config.toml for options." -t 10000
|
||||
fi
|
||||
5
bin/apps/nomarchy-voxtype-model
Executable file
5
bin/apps/nomarchy-voxtype-model
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
nnomarchy-launch-floating-terminal-with-presentation "voxtype setup model"
|
||||
nnomarchy-restart-waybar
|
||||
@@ -3,7 +3,7 @@ set -e
|
||||
|
||||
# Remove voxtype and its configurations.
|
||||
|
||||
if nomarchy-cmd-present voxtype; then
|
||||
if nnomarchy-cmd-present voxtype; then
|
||||
echo "Uninstall Voxtype to remove dictation."
|
||||
|
||||
# Remove services
|
||||
@@ -12,7 +12,7 @@ if nomarchy-cmd-present voxtype; then
|
||||
systemctl --user daemon-reload
|
||||
|
||||
# Remove packages and configs
|
||||
nomarchy-pkg-drop wtype voxtype-bin
|
||||
nnomarchy-pkg-drop wtype voxtype-bin
|
||||
rm -rf ~/.config/voxtype
|
||||
rm -rf ~/.local/share/voxtype
|
||||
else
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
if nomarchy-cmd-present voxtype; then
|
||||
if nnomarchy-cmd-present voxtype; then
|
||||
voxtype status --follow --extended --format json | while read -r line; do
|
||||
echo "$line" | jq -c '. + {alt: .class}'
|
||||
done
|
||||
@@ -8,4 +8,4 @@ if [[ $url =~ ^mailto: ]]; then
|
||||
web_url="https://app.hey.com/messages/new?to=$email"
|
||||
fi
|
||||
|
||||
exec nomarchy-launch-webapp "$web_url"
|
||||
exec nnomarchy-launch-webapp "$web_url"
|
||||
@@ -17,4 +17,4 @@ if [[ $url =~ ^zoom(mtg|us):// ]]; then
|
||||
fi
|
||||
fi
|
||||
|
||||
exec nomarchy-launch-webapp "$web_url"
|
||||
exec nnomarchy-launch-webapp "$web_url"
|
||||
@@ -60,7 +60,7 @@ else
|
||||
fi
|
||||
|
||||
# Use custom exec if provided, otherwise default behavior
|
||||
EXEC_COMMAND="${CUSTOM_EXEC:-nomarchy-launch-webapp $APP_URL}"
|
||||
EXEC_COMMAND="${CUSTOM_EXEC:-nnomarchy-launch-webapp $APP_URL}"
|
||||
|
||||
# Create application .desktop file
|
||||
DESKTOP_FILE="$HOME/.local/share/applications/$APP_NAME.desktop"
|
||||
@@ -8,7 +8,7 @@ DESKTOP_DIR="$HOME/.local/share/applications/"
|
||||
if (( $# == 0 )); then
|
||||
# Find all web apps
|
||||
while IFS= read -r -d '' file; do
|
||||
if grep -q '^Exec=.*\(nomarchy-launch-webapp\|nomarchy-webapp-handler\).*' "$file"; then
|
||||
if grep -q '^Exec=.*\(nnomarchy-launch-webapp\|nnomarchy-webapp-handler\).*' "$file"; then
|
||||
WEB_APPS+=("$(basename "${file%.desktop}")")
|
||||
fi
|
||||
done < <(find "$DESKTOP_DIR" -name '*.desktop' -print0)
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Remove all web apps installed via nomarchy-webapp-install.
|
||||
# Identifies web apps by their Exec pattern (nomarchy-launch-webapp or nomarchy-webapp-handler).
|
||||
# Remove all web apps installed via nnomarchy-webapp-install.
|
||||
# Identifies web apps by their Exec pattern (nnomarchy-launch-webapp or nnomarchy-webapp-handler).
|
||||
|
||||
set -e
|
||||
|
||||
@@ -12,7 +12,7 @@ echo "Scanning for web apps in $APP_DIR..."
|
||||
|
||||
webapp_desktop_files=()
|
||||
while IFS= read -r -d '' file; do
|
||||
if grep -q "Exec=nomarchy-launch-webapp\|Exec=nomarchy-webapp-handler" "$file" 2>/dev/null; then
|
||||
if grep -q "Exec=nnomarchy-launch-webapp\|Exec=nnomarchy-webapp-handler" "$file" 2>/dev/null; then
|
||||
webapp_desktop_files+=("$file")
|
||||
fi
|
||||
done < <(find "$APP_DIR" -maxdepth 1 -name "*.desktop" -print0 2>/dev/null)
|
||||
@@ -35,22 +35,22 @@ install_windows() {
|
||||
|
||||
check_prerequisites
|
||||
|
||||
nomarchy-pkg-add freerdp openbsd-netcat gum
|
||||
nnomarchy-pkg-add freerdp openbsd-netcat gum
|
||||
|
||||
mkdir -p "$HOME/.windows"
|
||||
mkdir -p "$HOME/.config/windows"
|
||||
mkdir -p "$HOME/.local/share/applications/icons"
|
||||
|
||||
# Install Windows VM icon and desktop file
|
||||
if [[ -f $OMARCHY_PATH/applications/icons/windows.png ]]; then
|
||||
cp "$OMARCHY_PATH/applications/icons/windows.png" "$HOME/.local/share/applications/icons/windows.png"
|
||||
if [[ -f $NOMARCHY_PATH/applications/icons/windows.png ]]; then
|
||||
cp "$NOMARCHY_PATH/applications/icons/windows.png" "$HOME/.local/share/applications/icons/windows.png"
|
||||
fi
|
||||
|
||||
cat << EOF | tee "$HOME/.local/share/applications/windows-vm.desktop" > /dev/null
|
||||
[Desktop Entry]
|
||||
Name=Windows
|
||||
Comment=Start Windows VM via Docker and connect with RDP
|
||||
Exec=uwsm app -- nomarchy-windows-vm launch
|
||||
Exec=uwsm app -- nnomarchy-windows-vm launch
|
||||
Icon=$HOME/.local/share/applications/icons/windows.png
|
||||
Terminal=false
|
||||
Type=Application
|
||||
@@ -177,7 +177,7 @@ EOF
|
||||
services:
|
||||
windows:
|
||||
image: dockurr/windows
|
||||
container_name: nomarchy-windows
|
||||
container_name: nnomarchy-windows
|
||||
environment:
|
||||
VERSION: "11"
|
||||
RAM_SIZE: "$SELECTED_RAM"
|
||||
@@ -236,7 +236,7 @@ EOF
|
||||
echo ""
|
||||
echo "Once finished, launch 'Windows' via Super + Space"
|
||||
echo ""
|
||||
echo "To stop the VM: nomarchy-windows-vm stop"
|
||||
echo "To stop the VM: nnomarchy-windows-vm stop"
|
||||
echo "To change resources: ~/.config/windows/docker-compose.yml"
|
||||
echo ""
|
||||
}
|
||||
@@ -269,7 +269,7 @@ launch_windows() {
|
||||
|
||||
# Check if config exists
|
||||
if [[ ! -f $COMPOSE_FILE ]]; then
|
||||
echo "Windows VM not configured. Please run: nomarchy-windows-vm install"
|
||||
echo "Windows VM not configured. Please run: nnomarchy-windows-vm install"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -282,7 +282,7 @@ launch_windows() {
|
||||
[[ -z $WIN_PASS ]] && WIN_PASS="admin"
|
||||
|
||||
# Check if container is already running
|
||||
CONTAINER_STATUS=$(docker inspect --format='{{.State.Status}}' nomarchy-windows 2>/dev/null)
|
||||
CONTAINER_STATUS=$(docker inspect --format='{{.State.Status}}' nnomarchy-windows 2>/dev/null)
|
||||
|
||||
if [[ $CONTAINER_STATUS != "running" ]]; then
|
||||
echo "Starting Windows VM..."
|
||||
@@ -292,21 +292,21 @@ launch_windows() {
|
||||
|
||||
if ! docker-compose -f "$COMPOSE_FILE" up -d 2>&1; then
|
||||
echo "❌ Failed to start Windows VM!"
|
||||
echo " Try checking: nomarchy-windows-vm status"
|
||||
echo " View logs: docker logs nomarchy-windows"
|
||||
echo " Try checking: nnomarchy-windows-vm status"
|
||||
echo " View logs: docker logs nnomarchy-windows"
|
||||
notify-send -u critical "Windows VM" "Failed to start Windows VM"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Waiting for Windows VM to start..."
|
||||
WAIT_COUNT=0
|
||||
until docker logs nomarchy-windows 2>&1 | grep -qi "windows started successfully"; do
|
||||
until docker logs nnomarchy-windows 2>&1 | grep -qi "windows started successfully"; do
|
||||
sleep 2
|
||||
WAIT_COUNT=$((WAIT_COUNT + 1))
|
||||
if (( WAIT_COUNT > 60 )); then # 2 minutes timeout
|
||||
echo ""
|
||||
echo "❌ Timeout: Windows VM failed to start within 2 minutes"
|
||||
echo " Check logs: docker logs nomarchy-windows"
|
||||
echo " Check logs: docker logs nnomarchy-windows"
|
||||
exit 1
|
||||
fi
|
||||
done
|
||||
@@ -315,7 +315,7 @@ launch_windows() {
|
||||
# Build the connection info
|
||||
if [[ $KEEP_ALIVE = "true" ]]; then
|
||||
LIFECYCLE="VM will keep running after RDP closes
|
||||
To stop: nomarchy-windows-vm stop"
|
||||
To stop: nnomarchy-windows-vm stop"
|
||||
else
|
||||
LIFECYCLE="VM will auto-stop when RDP closes"
|
||||
fi
|
||||
@@ -342,7 +342,7 @@ To stop: nomarchy-windows-vm stop"
|
||||
# If scale is less than 130%, don't set any scale (use default 100)
|
||||
|
||||
# Connect with RDP in fullscreen (auto-detects resolution)
|
||||
xfreerdp3 /u:"$WIN_USER" /p:"$WIN_PASS" /v:127.0.0.1:3389 -grab-keyboard /sound /microphone /clipboard /cert:ignore /title:"Windows VM - Nomarchy" /dynamic-resolution /gfx:AVC444 /floatbar:sticky:off,default:visible,show:fullscreen $RDP_SCALE
|
||||
xfreerdp3 /u:"$WIN_USER" /p:"$WIN_PASS" /v:127.0.0.1:3389 -grab-keyboard /sound /microphone /clipboard /cert:ignore /title:"Windows VM - Nnomarchy" /dynamic-resolution /gfx:AVC444 /floatbar:sticky:off,default:visible,show:fullscreen $RDP_SCALE
|
||||
|
||||
# After RDP closes, stop the container unless --keep-alive was specified
|
||||
if [[ $KEEP_ALIVE = "false" ]]; then
|
||||
@@ -353,7 +353,7 @@ To stop: nomarchy-windows-vm stop"
|
||||
else
|
||||
echo ""
|
||||
echo "RDP session closed. Windows VM is still running."
|
||||
echo "To stop it: nomarchy-windows-vm stop"
|
||||
echo "To stop it: nnomarchy-windows-vm stop"
|
||||
fi
|
||||
}
|
||||
|
||||
@@ -371,15 +371,15 @@ stop_windows() {
|
||||
status_windows() {
|
||||
if [[ ! -f $COMPOSE_FILE ]]; then
|
||||
echo "Windows VM not configured."
|
||||
echo "To set up: nomarchy-windows-vm install"
|
||||
echo "To set up: nnomarchy-windows-vm install"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
CONTAINER_STATUS=$(docker inspect --format='{{.State.Status}}' nomarchy-windows 2>/dev/null)
|
||||
CONTAINER_STATUS=$(docker inspect --format='{{.State.Status}}' nnomarchy-windows 2>/dev/null)
|
||||
|
||||
if [[ -z $CONTAINER_STATUS ]]; then
|
||||
echo "Windows VM container not found."
|
||||
echo "To start: nomarchy-windows-vm launch"
|
||||
echo "To start: nnomarchy-windows-vm launch"
|
||||
elif [[ $CONTAINER_STATUS = "running" ]]; then
|
||||
gum style \
|
||||
--border normal \
|
||||
@@ -391,16 +391,16 @@ status_windows() {
|
||||
"Web interface: http://127.0.0.1:8006" \
|
||||
"RDP available: port 3389" \
|
||||
"" \
|
||||
"To connect: nomarchy-windows-vm launch" \
|
||||
"To stop: nomarchy-windows-vm stop"
|
||||
"To connect: nnomarchy-windows-vm launch" \
|
||||
"To stop: nnomarchy-windows-vm stop"
|
||||
else
|
||||
echo "Windows VM is stopped (status: $CONTAINER_STATUS)"
|
||||
echo "To start: nomarchy-windows-vm launch"
|
||||
echo "To start: nnomarchy-windows-vm launch"
|
||||
fi
|
||||
}
|
||||
|
||||
show_usage() {
|
||||
echo "Usage: nomarchy-windows-vm [command] [options]"
|
||||
echo "Usage: nnomarchy-windows-vm [command] [options]"
|
||||
echo ""
|
||||
echo "Commands:"
|
||||
echo " install Install and configure Windows VM"
|
||||
@@ -413,10 +413,10 @@ show_usage() {
|
||||
echo " help Show this help message"
|
||||
echo ""
|
||||
echo "Examples:"
|
||||
echo " nomarchy-windows-vm install # Set up Windows VM for first time"
|
||||
echo " nomarchy-windows-vm launch # Connect to VM (auto-stop on exit)"
|
||||
echo " nomarchy-windows-vm launch -k # Connect to VM (keep running)"
|
||||
echo " nomarchy-windows-vm stop # Shut down the VM"
|
||||
echo " nnomarchy-windows-vm install # Set up Windows VM for first time"
|
||||
echo " nnomarchy-windows-vm launch # Connect to VM (auto-stop on exit)"
|
||||
echo " nnomarchy-windows-vm launch -k # Connect to VM (keep running)"
|
||||
echo " nnomarchy-windows-vm stop # Shut down the VM"
|
||||
}
|
||||
|
||||
# Main command dispatcher
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns the battery full capacity in Wh (rounded to whole number).
|
||||
# Used by nomarchy-battery-status for displaying battery capacity.
|
||||
# Used by nnomarchy-battery-status for displaying battery capacity.
|
||||
|
||||
battery_info=$(upower -i $(upower -e | grep BAT))
|
||||
|
||||
@@ -3,13 +3,13 @@
|
||||
# Designed to be run by systemd timer every 30 seconds and alerts if battery is low
|
||||
|
||||
BATTERY_THRESHOLD=10
|
||||
NOTIFICATION_FLAG="/run/user/$UID/nomarchy_battery_notified"
|
||||
BATTERY_LEVEL=$(nomarchy-battery-remaining)
|
||||
NOTIFICATION_FLAG="/run/user/$UID/nnomarchy_battery_notified"
|
||||
BATTERY_LEVEL=$(nnomarchy-battery-remaining)
|
||||
BATTERY_STATE=$(upower -i $(upower -e | grep 'BAT') | grep -E "state" | awk '{print $2}')
|
||||
|
||||
send_notification() {
|
||||
notify-send -u critical " Time to recharge!" "Battery is down to ${1}%" -i battery-caution -t 30000
|
||||
nomarchy-hook battery-low "$1"
|
||||
nnomarchy-hook battery-low "$1"
|
||||
}
|
||||
|
||||
if [[ -n $BATTERY_LEVEL && $BATTERY_LEVEL =~ ^[0-9]+$ ]]; then
|
||||
@@ -18,8 +18,8 @@ power_rate=$(echo "$battery_info" | awk '/energy-rate/ {
|
||||
}')
|
||||
|
||||
state=$(echo "$battery_info" | awk '/state/ { print $2; exit }')
|
||||
time_remaining=$(nomarchy-battery-remaining-time)
|
||||
capacity=$(nomarchy-battery-capacity)
|
||||
time_remaining=$(nnomarchy-battery-remaining-time)
|
||||
capacity=$(nnomarchy-battery-capacity)
|
||||
|
||||
if [[ $state == "charging" ]]; then
|
||||
echo " Battery ${percentage}% · ${time_remaining} to full · ${power_rate}W / ${capacity}Wh"
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Adjust brightness on the most likely display device.
|
||||
# Usage: nomarchy-brightness-display <step>
|
||||
# Usage: nnomarchy-brightness-display <step>
|
||||
|
||||
step="${1:-+5%}"
|
||||
|
||||
@@ -18,4 +18,4 @@ done
|
||||
brightnessctl -d "$device" set "$step" >/dev/null
|
||||
|
||||
# Use SwayOSD to display the new brightness setting.
|
||||
nomarchy-swayosd-brightness "$(brightnessctl -d "$device" -m | cut -d',' -f4 | tr -d '%')"
|
||||
nnomarchy-swayosd-brightness "$(brightnessctl -d "$device" -m | cut -d',' -f4 | tr -d '%')"
|
||||
@@ -8,5 +8,5 @@ else
|
||||
device="$(sudo asdcontrol --detect /dev/usb/hiddev* | grep ^/dev/usb/hiddev | cut -d: -f1)"
|
||||
sudo asdcontrol "$device" -- "$1" >/dev/null
|
||||
value="$(sudo asdcontrol "$device" | awk -F= '/BRIGHTNESS=/{print $2+0}')"
|
||||
nomarchy-swayosd-brightness "$(( value * 100 / 60000 ))"
|
||||
nnomarchy-swayosd-brightness "$(( value * 100 / 60000 ))"
|
||||
fi
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Adjust keyboard backlight brightness using available steps.
|
||||
# Usage: nomarchy-brightness-keyboard <up|down|cycle>
|
||||
# Usage: nnomarchy-brightness-keyboard <up|down|cycle>
|
||||
|
||||
direction="${1:-up}"
|
||||
|
||||
@@ -39,4 +39,4 @@ brightnessctl -d "$device" set "$new_brightness" >/dev/null
|
||||
|
||||
# Use SwayOSD to display the new brightness setting.
|
||||
percent=$((new_brightness * 100 / max_brightness))
|
||||
nomarchy-swayosd-kbd-brightness "$percent"
|
||||
nnomarchy-swayosd-kbd-brightness "$percent"
|
||||
@@ -3,4 +3,4 @@
|
||||
# Detect whether the computer is a Framework Laptop 16.
|
||||
|
||||
[[ $(cat /sys/class/dmi/id/sys_vendor 2>/dev/null) == "Framework" ]] &&
|
||||
nomarchy-hw-match "Laptop 16"
|
||||
nnomarchy-hw-match "Laptop 16"
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Match against the computer's DMI product name (case-insensitive).
|
||||
# Usage: nomarchy-hw-match "XPS"
|
||||
# Usage: nnomarchy-hw-match "XPS"
|
||||
|
||||
grep -qi "$1" /sys/class/dmi/id/product_name 2>/dev/null
|
||||
@@ -3,4 +3,4 @@
|
||||
# Detect whether the computer is a Microsoft Surface device.
|
||||
|
||||
[[ $(cat /sys/class/dmi/id/sys_vendor 2>/dev/null) == "Microsoft Corporation" ]] &&
|
||||
nomarchy-hw-match "Surface"
|
||||
nnomarchy-hw-match "Surface"
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Returns a list of all the available power profiles on the system.
|
||||
# Used by the Nomarchy Menu under Setup > Power Profile.
|
||||
# Used by the Nnomarchy Menu under Setup > Power Profile.
|
||||
|
||||
powerprofilesctl list |
|
||||
awk '/^\s*[* ]\s*[a-zA-Z0-9\-]+:$/ { gsub(/^[*[:space:]]+|:$/,""); print }' |
|
||||
@@ -1,5 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Restart makima - key remapping service for remapping Copilot key to Nomarchy Menu
|
||||
# Restart makima - key remapping service for remapping Copilot key to Nnomarchy Menu
|
||||
|
||||
sudo systemctl restart makima
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Toggle dedicated vs integrated GPU mode via supergfxd (for hybrid gpu laptops, like Asus G14).
|
||||
# Declarative enablement + Runtime mode switching for Nomarchy NixOS.
|
||||
# Declarative enablement + Runtime mode switching for Nnomarchy NixOS.
|
||||
|
||||
STATE_FILE="/etc/nixos/state.json"
|
||||
|
||||
@@ -30,14 +30,14 @@ case "$gpu_mode" in
|
||||
if gum confirm "Switch to Hybrid mode (enables dGPU) and reboot?"; then
|
||||
supergfxctl -m Hybrid
|
||||
echo "Switching to Hybrid mode..."
|
||||
nomarchy-system-reboot
|
||||
nnomarchy-system-reboot
|
||||
fi
|
||||
;;
|
||||
"Hybrid")
|
||||
if gum confirm "Switch to Integrated mode (disables dGPU) and reboot?"; then
|
||||
supergfxctl -m Integrated
|
||||
echo "Switching to Integrated mode..."
|
||||
nomarchy-system-reboot
|
||||
nnomarchy-system-reboot
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
@@ -1,14 +1,14 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Toggles wifi power saving declaratively.
|
||||
# Usage: nomarchy-wifi-powersave <on|off>
|
||||
# Usage: nnomarchy-wifi-powersave <on|off>
|
||||
|
||||
STATE_FILE="/etc/nixos/state.json"
|
||||
|
||||
case "$1" in
|
||||
on) value="true" ;;
|
||||
off) value="false" ;;
|
||||
*) echo "Usage: nomarchy-wifi-powersave <on|off>"; exit 1 ;;
|
||||
*) echo "Usage: nnomarchy-wifi-powersave <on|off>"; exit 1 ;;
|
||||
esac
|
||||
|
||||
sudo jq ".wifi.powersave = $value" "$STATE_FILE" > /tmp/state.json && sudo mv /tmp/state.json "$STATE_FILE"
|
||||
@@ -1,18 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Run a named hook, like post-update (available in ~/.config/nomarchy/hooks/post-update).
|
||||
|
||||
set -e
|
||||
|
||||
if (( $# < 1 )); then
|
||||
echo "Usage: nomarchy-hook [name] [args...]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
HOOK=$1
|
||||
HOOK_PATH="$HOME/.config/nomarchy/hooks/$1"
|
||||
shift
|
||||
|
||||
if [[ -f $HOOK_PATH ]]; then
|
||||
bash "$HOOK_PATH" "$@"
|
||||
fi
|
||||
@@ -1,5 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch the Nomarchy audio controls TUI (provided by wiremix).
|
||||
|
||||
nomarchy-launch-or-focus-tui wiremix
|
||||
@@ -1,7 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch the Nomarchy bluetooth controls TUI (provided by bluetui).
|
||||
# Also attempts to unblock bluetooth service if rfkill had blocked it.
|
||||
|
||||
rfkill unblock bluetooth
|
||||
exec nomarchy-launch-or-focus-tui bluetui
|
||||
@@ -1,7 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch a floating terminal with the Nomarchy logo presentation, then execute the command passed in, and finally end with the nomarchy-show-done presentation.
|
||||
# Used by actions such as Update System.
|
||||
|
||||
cmd="$*"
|
||||
exec setsid uwsm-app -- xdg-terminal-exec --app-id=org.nomarchy.terminal --title=Nomarchy -e bash -c "nomarchy-show-logo; $cmd; if (( \$? != 130 )); then nomarchy-show-done; fi"
|
||||
@@ -1,9 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch or focus on a given TUI identified by the passed in as the command.
|
||||
# Use by commands like nomarchy-launch-wifi to ensure there is only one wifi configuration screen open.
|
||||
|
||||
APP_ID="org.nomarchy.$(basename "$1")"
|
||||
LAUNCH_COMMAND="nomarchy-launch-tui $@"
|
||||
|
||||
exec nomarchy-launch-or-focus "$APP_ID" "$LAUNCH_COMMAND"
|
||||
@@ -1,5 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Launch the TUI command passed in as an argument in the default terminal with an org.nomarchy.COMMAND app id for styling.
|
||||
|
||||
exec setsid uwsm-app -- xdg-terminal-exec --app-id=org.nomarchy.$(basename $1) -e "$1" "${@:2}"
|
||||
@@ -1,5 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Overwrite the user config for fastfetch with the Nomarchy default.
|
||||
|
||||
nomarchy-refresh-config fastfetch/config.jsonc
|
||||
@@ -1,5 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Reload btop configuration (used by the Nomarchy theme switching).
|
||||
|
||||
pkill -SIGUSR2 btop
|
||||
@@ -1,5 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Reload hyprland configuration (used by the Nomarchy theme switching).
|
||||
|
||||
hyprctl reload >/dev/null
|
||||
@@ -1,5 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Reload mako configuration (used by the Nomarchy theme switching).
|
||||
|
||||
makoctl reload
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
nomarchy-restart-app swayosd-server
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
nomarchy-restart-app waybar
|
||||
@@ -1,22 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Setup makima - key remapping service for remapping Copilot key to Nomarchy Menu
|
||||
|
||||
CONFIG_FILE="$HOME/.config/makima/AT Translated Set 2 keyboard.toml"
|
||||
|
||||
if [[ ! -f $CONFIG_FILE ]]; then
|
||||
nomarchy-pkg-add makima-bin
|
||||
|
||||
mkdir -p "$HOME/.config/makima"
|
||||
cp "$OMARCHY_PATH/default/makima/AT Translated Set 2 keyboard.toml" "$CONFIG_FILE"
|
||||
|
||||
sudo mkdir -p /etc/systemd/system/makima.service.d
|
||||
sudo tee /etc/systemd/system/makima.service.d/override.conf >/dev/null <<EOF
|
||||
[Service]
|
||||
User=$USER
|
||||
Environment="MAKIMA_CONFIG=/home/$USER/.config/makima"
|
||||
EOF
|
||||
|
||||
sudo systemctl daemon-reload
|
||||
sudo systemctl enable --now makima 2>/dev/null || true
|
||||
fi
|
||||
@@ -1,15 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Build and run the Nomarchy VM (installed environment) for testing.
|
||||
|
||||
echo "Building Nomarchy VM (Installed Environment)..."
|
||||
echo "Note: To test the INSTALLER, run 'nomarchy-test-installer' instead."
|
||||
nix build .#nixosConfigurations.vm.config.system.build.vm
|
||||
|
||||
if [ $? -eq 0 ]; then
|
||||
echo "Success! Launching VM..."
|
||||
./result/bin/run-nomarchy-vm
|
||||
else
|
||||
echo "Error: VM build failed."
|
||||
exit 1
|
||||
fi
|
||||
@@ -1,7 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
CURRENT_THEME_NAME=$(cat "$HOME/.config/nomarchy/current/theme.name")
|
||||
THEME_USER_BACKGROUNDS="$HOME/.config/nomarchy/backgrounds/$CURRENT_THEME_NAME"
|
||||
|
||||
mkdir -p "$THEME_USER_BACKGROUNDS"
|
||||
nautilus "$THEME_USER_BACKGROUNDS"
|
||||
@@ -1,33 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# nomarchy-theme-install: Install a new theme from a git repo for Nomarchy
|
||||
# Usage: nomarchy-theme-install <git-repo-url>
|
||||
|
||||
if [[ -z $1 ]]; then
|
||||
echo -e "\e[32mSee https://manuals.omamix.org/2/the-nomarchy-manual/90/extra-themes\n\e[0m"
|
||||
REPO_URL=$(gum input --placeholder="Git repo URL for theme" --header="")
|
||||
else
|
||||
REPO_URL="$1"
|
||||
fi
|
||||
|
||||
if [[ -z $REPO_URL ]]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
THEMES_DIR="$HOME/.config/nomarchy/themes"
|
||||
THEME_NAME=$(basename "$REPO_URL" .git | sed -E 's/^nomarchy-//; s/-theme$//')
|
||||
THEME_PATH="$THEMES_DIR/$THEME_NAME"
|
||||
|
||||
# Remove existing theme if present
|
||||
if [[ -d $THEME_PATH ]]; then
|
||||
rm -rf "$THEME_PATH"
|
||||
fi
|
||||
|
||||
# Clone the repo directly to ~/.config/nomarchy/themes
|
||||
if ! git clone "$REPO_URL" "$THEME_PATH"; then
|
||||
echo "Error: Failed to clone theme repo."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Apply the new theme with nomarchy-theme-set
|
||||
nomarchy-theme-set $THEME_NAME
|
||||
@@ -1,8 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
{
|
||||
find ~/.config/nomarchy/themes/ -mindepth 1 -maxdepth 1 \( -type d -o -type l \) -printf '%f\n'
|
||||
find "$OMARCHY_PATH/themes/" -mindepth 1 -maxdepth 1 -type d -printf '%f\n'
|
||||
} | sort -u | while read -r name; do
|
||||
echo "$name" | sed -E 's/(^|-)([a-z])/\1\u\2/g; s/-/ /g'
|
||||
done
|
||||
@@ -1,9 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Refresh the current theme from its templates.
|
||||
|
||||
THEME_NAME_PATH="$HOME/.config/nomarchy/current/theme.name"
|
||||
|
||||
if [[ -f $THEME_NAME_PATH ]]; then
|
||||
nomarchy-theme-set "$(cat $THEME_NAME_PATH)"
|
||||
fi
|
||||
@@ -1,4 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
nomarchy-theme-set-keyboard-asus-rog
|
||||
nomarchy-theme-set-keyboard-f16
|
||||
@@ -1,7 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
ASUSCTL_THEME=~/.config/nomarchy/current/theme/keyboard.rgb
|
||||
|
||||
if nomarchy-cmd-present asusctl; then
|
||||
asusctl aura effect static -c $(sed 's/^#//' $ASUSCTL_THEME)
|
||||
fi
|
||||
@@ -1,5 +0,0 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
nomarchy-launch-floating-terminal-with-presentation "voxtype setup model"
|
||||
nomarchy-restart-waybar
|
||||
@@ -11,7 +11,7 @@ SWAPSIZE=$(( 1024 * ${SWAPSIZE_KB:-0} ))
|
||||
|
||||
HIBERNATION_IMAGE_SIZE=$(cat /sys/power/image_size)
|
||||
|
||||
if (( SWAPSIZE > HIBERNATION_IMAGE_SIZE )) && [[ -f /etc/mkinitcpio.conf.d/nomarchy_resume.conf ]]; then
|
||||
if (( SWAPSIZE > HIBERNATION_IMAGE_SIZE )) && [[ -f /etc/mkinitcpio.conf.d/nnomarchy_resume.conf ]]; then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
@@ -3,7 +3,7 @@
|
||||
# Removes hibernation setup: disables swap, removes swapfile, removes fstab entry,
|
||||
# removes resume hook, and removes suspend-then-hibernate configuration.
|
||||
|
||||
MKINITCPIO_CONF="/etc/mkinitcpio.conf.d/nomarchy_resume.conf"
|
||||
MKINITCPIO_CONF="/etc/mkinitcpio.conf.d/nnomarchy_resume.conf"
|
||||
|
||||
# Check if hibernation is configured
|
||||
if [[ ! -f $MKINITCPIO_CONF ]] || ! grep -q "^HOOKS+=(resume)$" "$MKINITCPIO_CONF"; then
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user