-
-
Notifications
You must be signed in to change notification settings - Fork 33
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
Tab Completion for bash #203
Comments
Cool idea @generalredneck! This is definitely not high priority, but might be a nice to have. I am going to put this in carbonite for now, but if you want to do some research and we get some general ideas going around from @pirog and @serundeputy, maybe it can be included in the future |
I support this but i also have no ideas on how to accomplish this and no desire to do any work to make it happen ;) aka someone else is going to have to take the lead here! |
I'll see what I can do. I don't know how to alter the deb package to do the install... be a learning speriance. |
@generalredneck im guessing these are going to be the relevant files you will want to look at
|
I played around with https://github.com/f/omelette as a plugin for proof of concept. It is lightweight, has zero dependencies, is cross-platform compatible and works with both zsh and bash. If anything, it may serve as inspiration for how to proceed if the Lando team builds the feature out from a scratch. Edit: Looks like yargs, which is already included in Lando, has this built-in for bash. |
@tylerssn do you have anything concrete yet? I'd be willing to do a little bit of coding to help make this happen, although I'm a novice at node. |
Given that yargs is already included in Lando and that Lando is not in the autocompletion business - Omelette may be a bit much to integrate at the moment, despite it's lightweight and platform compatibility. Yargs gives us bash autocompletion and Zsh can support it as well with the following two lines:
To see a functional proof of concept in Lando:
You can now execute Obstacles for integration with Lando:
|
@jcheek - Here's a working implementation that someone can take from here. I won't be spending much more time on it after this weekend. Features:
Setup:
Key Issue: I have a promise mess. |
For Ubuntu 18.10 I added the plugin in ~/.lando/plugins following the instructions, added the plugin in ~/.lando/config.yml But then I had the following error: I was using rc13 version of lando. |
Looks like this is fixed in the version 4.3.7 of pkg: vercel/pkg#461 |
@edurenye - My example was more than likely built on RC1 so you'd certainly have to make some changes to get this into a working state. |
That problem with node that was also showing up in the rc1 is gone now, the plugin is loaded fine without errors. This added the following to ~/.zshrc
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions and please check out this if you are wondering why we auto close issues. |
Do not close this issue, this is a really interesting feature |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions and please check out this if you are wondering why we auto close issues. |
unstale |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions and please check out this if you are wondering why we auto close issues. |
@edurenye - if it helps, testing this was tricky in the dev env when calling |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions and please check out this if you are wondering why we auto close issues. |
please reopen this :) |
From maintainer convos I know that we're looking at moving to a different CLI construction tool with Lando 4.x, probably in the next year. Added relevant tags and re-opened. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions and please check out this if you are wondering why we auto close issues. |
Will the use of oclif help fix this? Should we move this issue to https://github.com/lando/cli ? |
@edurenye i do think OCLIF has some utils around tab completion however. i think the difficulty is going to be around completion of commands that differ from app to app. |
Feature Request
As a lando user, I would like to be able to press the
<TAB>
key and have a list of options I can select from so that typing out commands is faster.This would probably take the form of a simple bash completions script. I don't have the gist of it but something along the lines of the following script in it's simplest form put into
/etc/bash_completion.d/
The text was updated successfully, but these errors were encountered: