-
-
Notifications
You must be signed in to change notification settings - Fork 143
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bind/run multiple actions at once #914
Comments
Idea from @calops for CLI:
Though, I'm not sure if you can run a clap parser on stdin to parse the arguments. |
You should be able to run a clap parser on any string manually. It would have to be a subset of the global parser but it sounds doable. |
Clap doesn't support it currently, someone mentioned this as a workaround:
This breaks |
This issue only seems to relate to chaining commands in the program arguments. You can still use the exact same workaround you're talking about with the contents of stdin instead of splitting on |
Allow binds to run several actions sequentially, e.g.:
And, more importantly, add some way to run several actions as a batch through IPC and
niri msg action
. This will allow doing several actions as one atomic sequence and with no delay in-between, which is currently impossible.Here the binds and the IPC part should be straightforward, but I'm not sure how to parse the arguments in
niri msg action
. Maybe clap offers something?Another question is what to do if only one action in the sequence fails a check like
allow-when-locked
. Here I guess we ignore just the action that fails the check, same as what would happen if you were to run severalniri msg action
commands one after another.The text was updated successfully, but these errors were encountered: