-
Notifications
You must be signed in to change notification settings - Fork 30
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
Feat: internal commands with spaces #161
Conversation
@fdncred yes, it works, but the dirty hack somehow worries me a little bit :-) |
The main reason for me to like the regex idea is automation. But in this case, we can probably also write a |
I just noticed that the |
Yes, as the |
Also keep in mind that in order to get commands and plugins with spaces in them, you have to have the plugins built, installed, and registered for this command below to work. Also, that command would get multiword aliases and custom commands too. scope commands | get name | where {' ' in $in} o> list This is the command below is probably more appropriate. We could also include # generated with Nu 0.100.1
help commands |
where command_type == built-in or command_type == plugin or command_type == keyword |
get name |
where {' ' in $in} |
Current implementation can't tell internals/externals from each other, if we want them highlighted differently, more complicated |
I'm not saying that they should be highlighted differently. I'm just saying that the help commands or scope commands only needs to list the appropriate things. e.g. custom commands should not be included in our list. |
Sure, this pr is just a demo, we should redesign pipeline to generate the list. |
I have the |
I don't think we want to do that because it would require downloading and building plugins and downloading and installing custom completions. Building plugins takes forever in CI. The list should really change much and I'd personally most complete list than just bare nushell if possible. |
Does your script above generate all 531 of those commands? If so, we can add that script along with the generated list file to the repo. But I guess only you can maintain that list right? We probably only get a small part of it with the same script? |
We probably should test the impact on performance, 531 seems to be a significant number. |
agreed. i just pushed my list to the pr. |
@fdncred Do we need |
We can remove any of them that we want. However, I'm not sure 19 commands will make any difference. These are just the custom completions I usually run with |
@fdncred we can keep it and update the test case, the performance loss is about 7~8%, |
ok, let's run with this. it's just software. If we don't like how it works, we can always revert/remove it. |
I was too slow on the thread of #161 , some necessary updates is not pushed on-time. 1. commands start with `overlay` and `export` are removed, they are treated as keywords 2. one test case with `cargo install` updated
For test purpose #156