dmenu-flexipatch
dmenu-flexipatch copied to clipboard
Is it possible to have dmenu return other exit codes on pressing `Alt-Enter` or other combination?
I am writing a script and want to have to possible set of actions based on which key was used to make the selection in dmenu. For example, I can either press Enter (return code 0) or Ctrl-Enter (return code 10). Both will only output one entry and based on the exit code, I can go for different actions in the script.
Is this possible?
Sounds like an idea that would likely conflict with many other ideas. Like how you can select more than one item for output or using the mouse to select options.
Rather than the exit code you could potentially use the separator patch and return either the text part or the value part depending on whether you press Enter or Alt+Enter for example. The default is to always return the value part.