#!/bin/sh set -e [ -n "$DEBUG" ] && set -x arg0=bemenu # prompt=${MENU_PROMPT:-󰈶 :} prompt=${MENU_PROMPT:-󰈶󰩤} main_color="#4E4371" args= idx=0 while test $# -gt $idx; do case "$1" in -run) arg0=bemenu-run prompt=" 󰏌 " shift ;; -drun) # arg0=$HOME/devel/upstream/github.com/Cloudef/bemenu/bemenu-drun; prompt=bin arg0=bemenu-drun prompt=" 󱂬 " main_color="#e03c8a" shift ;; -p) shift prompt="$1" shift ;; -x) shift MENU_PASSWORD=1 ;; esac idx=$((idx + 1)) done # HACK: https://github.com/Cloudef/bemenu/issues/5 args= [ -n "${MENU_PASSWORD}" ] && args="${args} --password" # make sure there we are the only running menu pgrep "${arg0}" && pkill "${arg0}" exec "${arg0}" \ --tb "$main_color" --tf '#fffffb' \ --hb "$main_color" --hf '#fffffb' \ --scb '#1c1c1c' --scf "$main_color" \ --prompt="${prompt}" \ ${args} \ "$@"