Open Martinsos opened 3 years ago
NOTE: installer is now in separate repo: https://github.com/wasp-lang/get-wasp .
I think I can work on this one.
I think I can work on this one.
That would be awesome, pls go for it!
I also just created this connected issue: https://github.com/wasp-lang/wasp/issues/754 .
We added mention of completion
to the help of Wasp CLI.
We have bash completion for Wasp thanks to @thvu11 ! In order to install it, user needs to run
wasp completion
to read the instructions and then run a couple of commands, which includes making decisions (decisions are hard!) like where to put the generated completion script.There are two points here:
wasp completion
?For discoverability, the easiest thing would be to add something to documentation (https://github.com/wasp-lang/wasp/tree/master/web/docs) -> we should certainly do that. We might also want to add info about
completion
command to the help that is printed when you type justwasp
in terminal.Next, we might want to inform users about this during the installation, in install script (https://github.com/wasp-lang/get-wasp/blob/master/installer.sh) -> something like "We have support for bash completion, run
wasp completion
to learn more!". Or, we could even add step to install script that asks: do you want us to install bash completion for you? Y/N? and if Y we do it automatically.Making installation simpler -> I think one big step would be telling users where to put the completion script. For me personally it was not easy to figure out where to put it. We could at least recommend them some paths. Next step would be for us to make that decision -> we could maybe put the script at the same place where we install wasp stuff (binary, data)? Also, we could even add that
source ...
line to the bash_profile/rc! I know some tools likenvm
andruby
add stuff like that on their own.We have seen netlify doing some nice things with their CLI, so it would probably be smart to again check how they do these things and maybe do it same as them, if we like what they do.