dotfiles-x11e6a46d6
use rofi for SUDO_ASKPASS
+10 −7
3 files changed
- M .config/shell/profile +1 −1
- D .local/bin/dmenupass +0 −6
- A .local/bin/rofipass +9 −0
| @@ -32,7 +32,7 @@ export MYSQL_HISTFILE="$XDG_CACHE_HOME/.mariadb_history" | |||
| 32 | 32 | export CUDA_CACHE_PATH="$XDG_CACHE_HOME/nv" | |
| 33 | 33 | ||
| 34 | 34 | # Other program settings | |
| 35 | − | export SUDO_ASKPASS="$HOME/.local/bin/dmenupass" | |
| 35 | + | export SUDO_ASKPASS="$HOME/.local/bin/rofipass" | |
| 36 | 36 | export FZF_DEFAULT_OPTS="--layout=reverse --height 40%" | |
| 37 | 37 | export ANDROID_SDK_HOME="${XDG_CONFIG_HOME:-$HOME/.config}/android" | |
| 38 | 38 | export ANDROID_HOME="$HOME/Android/Sdk/" | |
| @@ -1,6 +0,0 @@ | |||
| 1 | − | #!/bin/sh | |
| 2 | − | ||
| 3 | − | # This script is the SUDO_ASKPASS variable, meaning that it will be used as a | |
| 4 | − | # password prompt if needed. | |
| 5 | − | ||
| 6 | − | dmenu -P -p "$1" <&- && echo | |
| @@ -0,0 +1,9 @@ | |||
| 1 | + | #!/bin/sh | |
| 2 | + | # | |
| 3 | + | # Take password prompt from STDIN, print password to STDOUT | |
| 4 | + | # the sed piece just removes the colon from the provided | |
| 5 | + | # prompt: rofi -p already gives us a colon | |
| 6 | + | rofi -dmenu \ | |
| 7 | + | -password \ | |
| 8 | + | -no-fixed-num-lines \ | |
| 9 | + | -p "$(printf "$1" | sed s/://)" | |