custom user excmds that take arguments #56
|
If I add a custom excmd like this in I'd expect to be able to type The tests have something similar in glide/src/glide/browser/base/content/test/excmds/browser_excmds.ts Lines 237 to 241 in 107e240 api.excmds.execute("test_command arg1 arg2") directly.
When the user actually types it, we end up processing a glide/src/glide/toolkit/content/widgets/glide-commandline.ts Lines 348 to 362 in 107e240 is_known_command() doesn't return true, we discard the input arguments. And that function only checks the list of built-in excmds. So doing :tab_new https://example.com works (because it is a known command), but a custom excmd to do the same thing does not. So I think the bug may just be that is_known_command() should take into account user excmds?
|
Replies: 1 comment 2 replies
|
Thank you for the detailed bug report and investigating the root cause! I really appreciate it. I can reproduce and confirm that your suggested fix works, will push a fix for this in the next release. side note that I really need to get rid of the difference between user defined excmds and builtin ones, it's a hack really. |
Fixed in 81e21d0, thank you again for the brilliant report!