___________________________________
< man, i hate all these keybindings >
-----------------------------------
\ ,__,
\ (oo)____
(__) )\
||--|| *
"Rofi Command Palette" takes an inspiration from VSCode's command palette that has everything included including your custom commands and it fuzzy searches it.
- Uses .yaml file for configuration file so that you can no longer have the need to escape double quotes or something that needs it.
- Run as sudo implementation
- First add an initial config, it's up to you where to place it. Name it whatever you want, but the default one will be read on
~/.rofi-commands.yaml
. Heres an example on how it should look:
- name: Sleep
confirm: true
command: systemctl suspend
- name: Another Command
run_as_sudo: true
command: notify-send "Hello, World!"
- Launch
command-palette.sh
. - And it's done, now you can bind it to some key like $mod (alt or command key) + shift + p on sxhkd or something.
name:
used for the command's name.confirm:
used for indicating the command that it needs to be confirmed first (confirmation y/n).run_as_sudo:
used for indicating that the command has to be ran as root.command:
commands that will be executed.
- myrmidon for the "inspiration". I literally copy-pasted all it's code and then rewrite it with yq (even tho i only modified it a little, for example; running with sudo and .yaml replacement)
- rofi for being a wonderful dmenu replacement
- yq for command-line YAML, JSON, XML, CSV, TOML and properties processor.