Skip to content

Comments

ignore quoted characters when splitting keybindings into actions#3612

Merged
JoeKar merged 1 commit intomicro-editor:masterfrom
matthias314:m3/action-quote
Jan 20, 2025
Merged

ignore quoted characters when splitting keybindings into actions#3612
JoeKar merged 1 commit intomicro-editor:masterfrom
matthias314:m3/action-quote

Conversation

@matthias314
Copy link
Contributor

Currently a keybinding of the form

"F3": "command:run sh -c 'ls | wc -l'"

does not work because micro interprets &, | and , as separators between actions:
https://github.com/zyedidia/micro/blob/f49487dc3adf82ec5e63bf1b6c0ffaed268aa747/internal/action/bufpane.go#L103-L105
This PR fixes this by ignoring escaped and quoted characters when splitting a keybinding into actions.

@matthias314
Copy link
Contributor Author

I believe the latest version addresses all comments (which I've therefore marked as resolved). Let me know if that's not the case.

@dmaluka
Copy link
Collaborator

dmaluka commented Jan 19, 2025

LGTM. Thanks for the fix.

@JoeKar JoeKar merged commit f5debdf into micro-editor:master Jan 20, 2025
6 checks passed
@matthias314 matthias314 deleted the m3/action-quote branch January 20, 2025 20:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants