commit 93ee9f594c382982ad989cdf2229429c83cfb25f
parent 3648ba12ecf8707c54b6c48ed2826a53c1e5f887
Author: Andrew Laack <andrew@laack.co>
Date: Fri, 6 Mar 2026 14:54:42 -0600
Updated dmenu commands
Diffstat:
15 files changed, 22 insertions(+), 79 deletions(-)
diff --git a/abduco.sh b/abduco.sh
@@ -1,9 +1,6 @@
#!/bin/bash
if [ -n "$1" ]; then
- background=$1
- foreground=$2
- highlight=$3
prompt="abduco dir:"
# exclude git repos which have lots of sub-dirs,
@@ -17,7 +14,7 @@ if [ -n "$1" ]; then
! -path '*/.firefox/*' \
! -path '*/.mozilla/*' \
! -path '*/.git/*' \
- | dmenu -l 15 -i -p "$prompt" -nb "$background" -nf "$foreground" -sb "$highlight" -sf "$foreground")
+ | dmenu -l -p "$prompt")
# Check if a directory was selected
if [ -z "$directory" ]; then
diff --git a/attach.sh b/attach.sh
@@ -8,10 +8,7 @@
if [ -n "$1" ]; then
prompt="session:"
- background=$1
- foreground=$2
- highlight=$3
- dmenu_cmd="dmenu -l 15 -i -nb \"$background\" -nf \"$foreground\" -sb \"$highlight\" -sf \"$foreground\" -p \"$prompt\""
+ dmenu_cmd="dmenu -p \"$prompt\""
selection=$(tmux ls | awk '{print $1}' | sed 's/:$//' | eval $dmenu_cmd)
if [ -z "$selection" ]; then
diff --git a/dmenu.sh b/dmenu.sh
@@ -8,11 +8,6 @@ if [ $# -eq 0 ]
selection=$(compgen -c | fzf)
nohup $selection &>/dev/null &
else
- background=$1
- foreground=$2
- highlight=$3
-
prompt="run:"
-
- dmenu_run -l 15 -i -nb "$background" -nf "$foreground" -sb "$highlight" -sf "$foreground" -p "$prompt"
+ dmenu_run -p "$prompt"
fi
diff --git a/find-music.sh b/find-music.sh
@@ -3,16 +3,9 @@
# I have my music broken down by artist, but there is no reason
# why if you have it by album that this wouldn't work.
-background=$2
-foreground=$3
-highlight=$4
-
-
-
-
prompt="play:"
-dmenu_cmd="dmenu -l 15 -i -nb \"$background\" -nf \"$foreground\" -sb \"$highlight\" -sf \"$foreground\" -p \"$prompt\""
+dmenu_cmd="dmenu -p \"$prompt\""
artistDirectory=$1
out="$1$(ls "$artistDirectory" | eval $dmenu_cmd)"
diff --git a/init-screen.sh b/init-screen.sh
@@ -6,16 +6,12 @@
prompt="init dir:"
-background=$1
-foreground=$2
-highlight=$3
-
# exclude git repos which have lots of sub-dirs,
# .cache which has a ton of firefox crap
# .local because I never really go there and lots
# of crap there too, and finally .firefox.
-dmenu_cmd="dmenu -l 15 -i -nb \"$background\" -nf \"$foreground\" -sb \"$highlight\" -sf \"$foreground\" -p \"$prompt\""
+dmenu_cmd="dmenu -p \"$prompt\""
directory=$(find ~ -type d \
! -path '*/.local/*' \
diff --git a/installers/arch-public-installation.sh b/installers/arch-public-installation.sh
@@ -1,7 +1,7 @@
#!/bin/bash
# Full arch installer (publicly accessible resources only)
-sudo pacman -S git gcc make xorg-server libxft libxinerama freetype2 pkgconf ttf-fira-code zoxide fzf openssh less arandr dmenu pass pass-otp xclip newsboat xorg-xsetroot base-devel i3lock pandoc entr ripgrep wget jq man-db btop tmux rsync cronie mpv podman pavucontrol otf-latinmodern kwallet proton-vpn-gtk-app proton-vpn-cli tk brightnessctl zip unzip signal-desktop xorg-xset lynx figlet flameshot feh ffmpeg zathura-pdf-mupdf websocat xhost-xorg yt-dlp qemu-full qbittorrent
+sudo pacman -S git gcc make xorg-server libxft libxinerama freetype2 pkgconf ttf-fira-code zoxide fzf openssh less arandr pass pass-otp xclip newsboat xorg-xsetroot base-devel i3lock pandoc entr ripgrep wget jq man-db btop tmux rsync cronie mpv podman pavucontrol otf-latinmodern kwallet proton-vpn-gtk-app proton-vpn-cli tk brightnessctl zip unzip signal-desktop xorg-xset lynx figlet flameshot feh ffmpeg zathura-pdf-mupdf websocat xhost-xorg yt-dlp qemu-full qbittorrent
# xhost-xorg for containers to use my x server
diff --git a/pass.sh b/pass.sh
@@ -18,17 +18,10 @@ password_files=( "${password_files[@]#"$prefix"/}" )
password_files=( "${password_files[@]%.gpg}" )
-background=$1
-foreground=$2
-highlight=$3
-
prompt="account:"
-
-dmenu_cmd="dmenu -l 15 -i -nb \"$background\" -nf \"$foreground\" -sb \"$highlight\" -sf \"$foreground\" -p \"$prompt\""
-password=$(printf '%s\n' "${password_files[@]}" | eval "$dmenu_cmd" "$@")
-
-
+dmenu_cmd="dmenu -p \"$prompt\""
+password=$(printf '%s\n' "${password_files[@]}" | eval "$dmenu_cmd")
# Handle otp or passwords
if [[ "$password" == *totp* ]]; then
diff --git a/power.sh b/power.sh
@@ -1,18 +1,14 @@
#!/bin/bash
-background=$1
-foreground=$2
-highlight=$3
-
prompt="power:"
-dmenu_cmd="dmenu -l 15 -i -nb \"$background\" -nf \"$foreground\" -sb \"$highlight\" -sf \"$foreground\" -p \"$prompt\""
+dmenu_cmd="dmenu -p \"$prompt\""
opts=("suspend" "reboot" "hibernate" "poweroff")
selected_item=$(echo "${opts[@]}" | tr ' ' '\n' | eval $dmenu_cmd)
-# no need to verify a selection was made; no selection just gives an output.
-
-sleep .1
-systemctl $selected_item
+if [ -n "$selected_item" ]; then
+ sleep .1
+ systemctl $selected_item
+fi
diff --git a/ranger.sh b/ranger.sh
@@ -1,11 +1,6 @@
#!/bin/bash
input_dir="$1"
-background=$2
-foreground=$3
-highlight=$4
-
-
directory=$(find $input_dir -type d \
! -path '*/.local/*' \
@@ -16,7 +11,7 @@ directory=$(find $input_dir -type d \
! -path '*/.git/' \
! -path '*/git/*' \
! -path '*/docker/*' \
- | dmenu -l 15 -i -p "ranger dir:" -nb "$background" -nf "$foreground" -sb "$highlight" -sf "$foreground")
+ | dmenu -l 15 -i -p "ranger dir:")
if [ -n "$directory" ]; then
diff --git a/rsync.sh b/rsync.sh
@@ -6,13 +6,10 @@ if [ $# -eq 0 ]
then
SELECTION=$(echo -e $OPTIONS| fzf)
else
- background=$1
- foreground=$2
- highlight=$3
prompt="rsync:"
- dmenu_cmd="dmenu -l 15 -i -nb \"$background\" -nf \"$foreground\" -sb \"$highlight\" -sf \"$foreground\" -p \"$prompt\""
+ dmenu_cmd="dmenu -p \"$prompt\""
SELECTION=$(echo -e $OPTIONS | eval "$dmenu_cmd" "$@")
fi
diff --git a/search.sh b/search.sh
@@ -1,12 +1,9 @@
#!/bin/bash
-background=$1
-foreground=$2
-highlight=$3
prompt="search:"
-dmenu_cmd="dmenu -l 15 -i -nb $background -nf $foreground -sb $highlight -sf $foreground -p URL:"
+dmenu_cmd="dmenu -p url:"
#urls=$(awk '{print $1}' ~/.config/qutebrowser/bookmarks/urls)
diff --git a/tabbed.sh b/tabbed.sh
@@ -1,8 +1,5 @@
#!/bin/bash
-background=$1
-foreground=$2
-highlight=$3
prompt="tabbed dir:"
# exclude git repos which have lots of sub-dirs,
@@ -16,7 +13,7 @@ directory=$(find ~ -type d \
! -path '*/.firefox/*' \
! -path '*/.mozilla/*' \
! -path '*/.git/*' \
- | dmenu -l 15 -i -p "$prompt" -nb "$background" -nf "$foreground" -sb "$highlight" -sf "$foreground")
+ | dmenu -p "$prompt" )
# Check if a directory was selected
if [ -z "$directory" ]; then
diff --git a/tmux.sh b/tmux.sh
@@ -1,8 +1,5 @@
#!/bin/bash
-background=$1
-foreground=$2
-highlight=$3
prompt="tmux dir:"
# exclude git repos which have lots of sub-dirs,
@@ -16,7 +13,7 @@ directory=$(find ~ -type d \
! -path '*/.firefox/*' \
! -path '*/.mozilla/*' \
! -path '*/.git/*' \
- | dmenu -l 15 -i -p "$prompt" -nb "$background" -nf "$foreground" -sb "$highlight" -sf "$foreground")
+ | dmenu -p "$prompt")
# Check if a directory was selected
if [ -z "$directory" ]; then
diff --git a/vm-manager.sh b/vm-manager.sh
@@ -5,13 +5,10 @@ OPTIONS=$(find ~/vms -mindepth 1 -maxdepth 1 -type f)
if [ $# -eq 0 ]; then
SELECTION=$(echo "$OPTIONS" | fzf)
else
- background=$1
- foreground=$2
- highlight=$3
- prompt="VM:"
+ prompt="vm:"
- dmenu_cmd="dmenu -l 15 -i -nb \"$background\" -nf \"$foreground\" -sb \"$highlight\" -sf \"$foreground\" -p \"$prompt\""
+ dmenu_cmd="dmenu -p \"$prompt\""
SELECTION=$(echo "$OPTIONS" | eval "$dmenu_cmd")
fi
diff --git a/zathura.sh b/zathura.sh
@@ -2,14 +2,10 @@
pdfs=$(find ~ -type f -iname '*.pdf')
-
-background=$1
-foreground=$2
-highlight=$3
prompt="pdf:"
-dmenu_cmd="dmenu -l 15 -i -nb \"$background\" -nf \"$foreground\" -sb \"$highlight\" -sf \"$foreground\" -p \"$prompt\""
-pdf=$(printf "%s\n" "$pdfs" | eval "$dmenu_cmd" "$@")
+dmenu_cmd="dmenu -p \"$prompt\""
+pdf=$(printf "%s\n" "$pdfs" | eval "$dmenu_cmd")
if [ -n "$pdf" ]; then
zathura "$pdf"