Use system zsh plugins, remove redundant waybar network modules

- Source zsh-autosuggestions and zsh-syntax-highlighting from
  /usr/share/zsh/plugins/ instead of oh-my-zsh custom dir
- Add both as official packages
- Remove waybar network and custom/vpn modules (nm-applet covers this)
- Move tray from modules-left to first position in modules-right
This commit is contained in:
nevaforget 2026-03-31 10:27:53 +02:00
parent ca7f9bb79e
commit 077e852b3b
4 changed files with 9 additions and 42 deletions

View File

@ -117,12 +117,12 @@ if command -v fzf &>/dev/null; then
export FZF_ALT_C_OPTS="--preview 'eza --tree --color=always {} | head -200'"
fi
# --- Plugins (oh-my-zsh) ---
if [[ -d "${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting" ]]; then
source "${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh"
# --- Plugins (system packages) ---
if [[ -f /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh ]]; then
source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
fi
if [[ -d "${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions" ]]; then
source "${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh"
if [[ -f /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh ]]; then
source /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh
ZSH_AUTOSUGGEST_STRATEGY=(history completion)
fi

View File

@ -8,7 +8,6 @@
"modules-left": [
"group/sys",
"niri/workspaces",
"tray",
"wlr/taskbar",
"niri/window"
],
@ -16,9 +15,10 @@
],
"modules-right": [
"tray",
"mpris",
"custom/cpugov",
"group/net",
"bluetooth",
"group/sound",
"backlight",
"battery",
@ -34,14 +34,6 @@
"privacy"
]
},
"group/net": {
"orientation": "inherit",
"modules": [
"custom/vpn",
"network",
"bluetooth"
]
},
"group/stats": {
"orientation": "inherit",
"modules": [
@ -73,23 +65,6 @@
"clock"
]
},
"network": {
"format-wifi": "{icon}",
"format-ethernet": " {ifname}",
"format-disconnected": "󰱟 Offline",
"tooltip-format": "󰊗 {ifname} via {gwaddr}",
"tooltip-format-wifi": " WiFi {essid} ({signalStrength}%)",
"tooltip-format-ethernet": "󰱔 {ifname}",
"tooltip-format-disconnected": "Disconnected",
"on-click": "nm-connection-editor",
"format-icons": [
"󱛅",
"󱛂",
"󱛃",
"󱚽"
],
"max-length": 5
},
"tray": {
"icon-size": 15,
"spacing": 10
@ -364,14 +339,6 @@
"tooltip-format-activated": "󱎴 No Lockscreen on idle",
"tooltip-format-deactivated": "󰷛 Lockscreen on idle"
},
"custom/vpn": {
"format": "󰖂",
"exec": "echo '{\"class\": \"connected\", \"tooltip\": \"VPN Connected\"}'",
"exec-if": "nmcli -t -f TYPE,STATE connection show --active | grep -qE '^(vpn|wireguard):'",
"return-type": "json",
"interval": 5,
"signal": 9
},
"power-profiles-daemon": {
"format": "{icon}",
"tooltip-format": "Power profile: {profile}\nDriver: {driver}",

View File

@ -42,7 +42,6 @@ window#waybar {
#memory,
#bluetooth,
#temperature,
#network,
#pulseaudio,
#tray,
#mode,
@ -59,7 +58,6 @@ window#waybar {
#custom-gpu-usage,
#custom-cpugov,
#custom-dnd,
#custom-vpn.connected,
#power-profiles-daemon,
#privacy,
#gamemode,

View File

@ -14,6 +14,8 @@ zip
# Shell & Terminal
zsh
zsh-autosuggestions
zsh-syntax-highlighting
foot
foot-terminfo
bat