forked from colonelpanic/dotfiles
[Linux] Add rofi_command.sh
This commit is contained in:
parent
993a79e915
commit
3676f88e23
11
dotfiles/lib/bin/rofi_command.sh
Executable file
11
dotfiles/lib/bin/rofi_command.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/usr/bin/env bash
|
||||
function get_all_commands {
|
||||
IFS=:
|
||||
for exec_path in $PATH; do
|
||||
test -r "$exec_path" && \
|
||||
find "$exec_path" -maxdepth 1 -executable ! -type d -printf "%f\n"
|
||||
done
|
||||
}
|
||||
|
||||
selected=$(get_all_commands | rofi -dmenu -i)
|
||||
"$selected"
|
Loading…
Reference in New Issue
Block a user