-
Notifications
You must be signed in to change notification settings - Fork 25
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
Suggested Changes #3
Comments
I think adding a
This is good. It is breaking, but it should have been
Bring them on
I find that autocompletion is really slow because it has to hit k8s for the answers. Are you proposing some sort of caching? I'm interested in this.
Yes
Yes
Yes
All the things! Thank you for making this plugin better for everyone. |
I haven't done the completions yet. Ill look into it though, I am not sure how I am going to do that. I need to go through and make sure what I have isn't conflicting with what is in this plugin. Ill probably will make a pull request next week. |
Awesome; Don't be afraid of making multiple pulls to get the easy stuff in first. I'm happy to help brainstorm the completions with you. Another possibility would be to search through your shell history for auto-completion because I have found myself doing the same thing often. |
Ran across kubectl plugin in zsh. Its auto-complete works fine for me. They have a bunch of aliases as well, but I prefer the ones I have proposed. Not sure why they are not on the plugin list, on the wiki. Regardless, Ill have some more stuff to push in the future. Something to consider, is to add the plugin to oh-my-zsh. Perhaps to the external plugins? |
I think this is a good suggestion, and I've been mulling it over. Now that you've helped turned this into something actually useful, I think it's a good idea. |
Do you have a problem adding a little awk into the mix? Being able to search for things across namespaces with regular expressions is useful. In particular, I have # Search for regular expression across all resources and namespaces
kfind <regular expression>
# kpfind restricts search to pods with the same usage. An example is to search for all running pods
kpfind Running |
Totally cool with adding |
Next things Im going to work on:
|
👍 awesome |
So, I think I might make a PR to switch this to a bash plugin rather than explicitly a zsh plugin. That way more people can use it if they would like to with no effect on the zsh users. |
I believe it is currently incompatible with bash. I'm not opposed to changing it to a bash plugin, and think I would prefer that. Edit: It would not take long at all to convert what is incompatible though. I think it is just the read commands. |
Ill work on getting a bash version going soon, particularly as I will have some use for it. Would we want to have a separate project? |
I've been thinking about that. I think the name So, it looks like we have three options:
Looking at the Github docs for renaming a repository
So, simply renaming is a viable option. The benefits of keeping the same repository is that all forks will automatically still point to this repo. So, I'm open to any of the three options, but I think renaming may be best. Either way we will need to come up with a new name. Off the top of my head I've got |
I think renaming is fine. How about |
Another idea, I have been writing a script to create small base templates for deployments, jobs, etc. Would we want to add that functionality? The aim is just to create a base yaml file, and I don't think it should really become anything more than that. |
Both of those suggestions sound reasonable to me 👍 |
Okay! I renamed the plugin! 🎉We are now kube-aliases. I also pushed a commit to master removing the environment variable stuff which isn't super useful to the general public. I think the next big useful thing we can do is make this a bash plugin vs. a zsh plugin. That'll let a lot more people use the plugin (and maybe find it too) |
Ill work on making it a bash plugin. |
Awesome. I think we'll have to change the filetype, and perhaps also have a .plugin.zsh file that loads our main code so that zsh still can locate the plugin. I can also do some research. |
While we are changing plugin to a bash one, perhaps we can add a man page. |
That's a great idea. I'll take a look at the man page format |
Do you think I could be made a contributor? If so, I would like to structure master to require all merges to be reviewed, and start a develop branch that we can merge into from any feature branches. Understand if this is not something you want to do. |
I could swear I had already added you as a contributor. Definitely feel free to make as many changes as you'd like. I trust your judgement 👍 |
Made a develop branch. It should handle bash and zsh. In zsh autocomplete should be working. |
In the develop branch, |
Sorry, I haven't been responding in a timely manner. I think the changes you're making are great. I'll ponder the |
How about |
That is fine with me. |
Lets not merge. I want kstatus to grab everything in the current namespace, and a flag or something to grab it across all namespaces. Currently, it grabs across all namespaces. Probably should be able to specify which namespace to run this on. |
Things Im thinking about.
|
That sounds like good behavior to me
Yeah, this project is seriously missing specs. The aliases could actually be done in quite a DRY way which makes sure everything is working as suspected. Would we want to use a k8s cluster for testing? |
That is not a bad idea. Are you thinking Minikube? Though it may be possible to mock the return values for kubectl. We don’t need to test for kubectl behavior. I think that’s out of scope. Definitely started to add a lot more stuff than I initially expected. Was just adding aliases I was commonly using, and some functionality. Definitely can be cleaned up. Perhaps we should explicitly write out the desired features/specs? |
Yeah. However, should we mock the return values, or just wait for kubectl to return them? I feel like if we mock the return values, then we may make a mistake with the test and have it return data it wouldn't. |
That is very true. I started a project. Help us keep track with what we are working on. Or we can do something else. Im pretty open. |
That's perfect |
Sorry for not working on it for a bit. I have been caught up at work. Will be doing some stuff this week. |
No worries! |
I just ran across this project, it looks great. I think that the easiest way to make it also be bash-compatible is probably to convert the aliases to scripts in a bin directory and then add:
to the plugin.zsh file. This also makes it easier to add ruby/python/whatever scripts to the plugin later if you find/write something that isn't a shell script. |
Thank ya. Will be doing this. Assuming Dbz is good with this. |
Oh yeah, this is a great suggestion 👍 |
Ive had messages of Edit: This would also clear up some issues with |
I've been thinking about this a lot recently. How do we feel about I think as we get more users, it'll be nice to deprecate before making breaking changes. |
I am a fan of vim bindings, but if we shift describe to I think we should talk a little bit more about the aliases as well. Particularly since this would be breaking. We can make a release, and then start keeping a change log. That way someone could go back if they so choose. If we automate the creation of the aliases, we should be able to allow users to redefine their own aliases. Maybe we should get a slack channel/irc/discord and chat about it a bit? |
Trying out some automated function creations. Not final. Also working on playing around with reading custom alias creation. |
@patmessina do you want to join my slack, and we can make a channel to chat about this? |
Done |
Want to propose some changes, and additions. I will be more than happy to make them myself. Particularly since I have a lot of this done already.
kc
tok
kcl
tok
n
tons
to represent namespaces and usen
for nodesLet me know what you want, if anything.
The text was updated successfully, but these errors were encountered: