Skip to content
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

kubectl resources autocompletion #2055

Closed
giolf opened this issue Nov 6, 2022 · 107 comments
Closed

kubectl resources autocompletion #2055

giolf opened this issue Nov 6, 2022 · 107 comments
Labels
Feature requests Feature Requests

Comments

@giolf
Copy link

giolf commented Nov 6, 2022

Describe the solution you'd like?

Currently warp allows to autocomplete kubectl commands like:
kubectl get or kubectl describe

However it doesn't provide resources autocompletion, for example:
if you type: kubectl describe pod -n my-namespace and then if you press TAB it doesn't show you the list of the pods in that particular namespace.

I tried to setup on my .zshrcfile the following instruction:

# kubectl config
source <(kubectl completion zsh)

and on iTerm2 it works, but not in warp.

I think it would be super cool to provide this extra layer of autocompletion (similarly to the autocompletion warp offer with git)

How important is this feature to you?

4

@dannyneira
Copy link
Member

dannyneira commented Nov 7, 2022

Thanks for this feature request!

To anyone else interested in this feature, please add a :+1: to the original post at the top to signal that you want this feature, and subscribe if you'd like to be notified.

@pierre-mike-pge
Copy link

+1

7 similar comments
@cedi
Copy link

cedi commented Nov 12, 2022

+1

@giolf
Copy link
Author

giolf commented Nov 12, 2022

+1

@vlad-artyomov
Copy link

+1

@macro-dadt
Copy link

+1

@muneebshahid
Copy link

+1

@pavan2004it
Copy link

+1

@piavgh
Copy link

piavgh commented Nov 30, 2022

+1

@piavgh
Copy link

piavgh commented Nov 30, 2022

After having this feature, I will remove iTerm2 😄

@lummie
Copy link

lummie commented Nov 30, 2022

+1

@RapidIE
Copy link

RapidIE commented Nov 30, 2022

+1
+10
+1000 =)

@yevhenvolchenko
Copy link

+1
image
given kubernetes has extensible api having resources autocomplete is very important; native kubectl autocomplete has it for a reason!

@unbreakabl3
Copy link

+1 for that functionality

@vincent-at-trust
Copy link

+1

2 similar comments
@lkoniecz
Copy link

lkoniecz commented Dec 8, 2022

+1

@pavan2004it
Copy link

+1

@gomgomshrimp
Copy link

gomgomshrimp commented Dec 14, 2022

+1
This feature is very important.
People who often work with Kubernetes avoid warp because it doesn't support this feature.

@Elias-Chairi
Copy link

+1

@ovstuckrad
Copy link

Definitely need this to use Warp!

@ErlendFax
Copy link

+1

3 similar comments
@clementblaise
Copy link

+1

@MiddleCloud
Copy link

+1

@domechn
Copy link

domechn commented Jan 2, 2023

+1

@hreinking
Copy link

+1, a deal-breaker for me, and loving Warp so far.

@warpdotdev-devx warpdotdev-devx bot added the Feature requests Feature Requests label Jan 10, 2023
@nianyush
Copy link

+1

3 similar comments
@ebenezar-mccoy
Copy link

+1

@rayanebel
Copy link

+1

@fatalwithin
Copy link

+1

@imans777
Copy link

imans777 commented Nov 5, 2023

+1

4 similar comments
@JonasHess
Copy link

+1

@lieberlois
Copy link

+1

@valdirjunior011
Copy link

+1

@jzuijlek
Copy link

jzuijlek commented Nov 8, 2023

+1

@noahzweben
Copy link

noahzweben commented Nov 8, 2023

Hi all - I'm Noah, a PM at Warp. We finally have a Warp demo build that has support for kubernetes completions!

Since we don't use kubernetes at Warp, we're looking for people who want to test this in the wild! If you're interested in trialing kubernetes completions before we publicly release it, please email me at noah@warp.dev

It adds support for suggesting:

  • k8s resources
  • global options (e.g. kubectl options)
  • when --namespace and/or --kubeconfig are supplied, scope down suggestions to the specified namespace/kubeconfig

@that70schris
Copy link

is it possible to add support for kubecolor as well?

@dannyneira
Copy link
Member

Good news folks! The latest version of Warp now supports additional kubectl completions, including suggestions for resources, global options, and namespaces!

CleanShot 2023-12-01 at 09 29 51

Closing as completed, but please feel free to let us know if any bugs by opening a new GitHub issue.

@Pger-Y
Copy link

Pger-Y commented Dec 8, 2023

Cool feature!!!Have been used for several days, but there is still some suggestions,only typing kubectl there is k8s-context showing in prompt,i think it can be shown all the time,or type k,because we all alias kubectl as k :(
Thanks :)

@schabrolles
Copy link

Yes, that's a good step. Thank hope to have openshift cli soon (oc) which is based on kubectl.

@zachbai
Copy link

zachbai commented Dec 8, 2023

@that70schris saw you opened #3922 -- I have that on my slate so should be able to get to it within the coming weeks. Will update that issue when available

@imans777
Copy link

imans777 commented Dec 9, 2023

Cool feature!!!Have been used for several days, but there is still some suggestions,only typing kubectl there is k8s-context showing in prompt,i think it can be shown all the time,or type k,because we all alias kubectl as k :( Thanks :)

You can use a workaround here, there's a feature in Warp: "Expand aliases as you type". when you enable this, whenever you type k it automagically converts it to kubectl and then you can have all kubectl autocompletion active! This is also useful for other commands or aliases that you've set.

@AdamGold
Copy link

Hey, there's a problem with auto completing kubectl logs -- it doesn't autocomplete the resource name until you do kubectl logs pod ..... but that's not how kubectl command works with logs, it expects the resource name right after kubectl logs.

@lkoniecz
Copy link

alias k='/opt/homebrew/bin/kubectl'

does not seem to be working with aliases, or is it only me?

regards

@rasifdo
Copy link

rasifdo commented Dec 18, 2023

finally one of the most awaited features! hoping the team fixes autocompletion for 'k logs' as @AdamGold mentioned

@dannyneira
Copy link
Member

dannyneira commented Dec 18, 2023

@lkoniecz Yes, the alias should work, even with Alias Expansion disabled.

@lkoniecz
Copy link

@dannyneira I don;t think I need to disable that - it still works with kubectl.

@imans777
Copy link

just to make sure this is not missed, I'm copying my comment about my experience on kubectl missing autocompletions here too:
#652 (comment)

@nizametdinovcrx
Copy link

Hey, there's a problem with auto completing kubectl logs -- it doesn't autocomplete the resource name until you do kubectl logs pod ..... but that's not how kubectl command works with logs, it expects the resource name right after kubectl logs.

Is this resolved?

@zcl0621
Copy link

zcl0621 commented Feb 28, 2024

@nizametdinovcrx also not support...

@cx2c
Copy link

cx2c commented Mar 6, 2024

I need type external pod to complet pod name. but kubectl logs -n xxx pod xxxx is not a kubectl command
image

@yura-kutsiy
Copy link

Join the open issue (related kubectl log autocompletion feature) and leave your thumbs up.

#3958

@rubengmurray
Copy link

Doesn't work for me at all in conjuction with ohmyzsh

@mostafamoq
Copy link

need this future , kubectl-autocomplete not working on warp over zsh ohmyzsh

@kopaygorodsky
Copy link

kubectl logs still does not work as some other items. Would be nice to be able to disable autocomplete for certain binaries.

@ghost
Copy link

ghost commented Jul 3, 2024

any updates on the resource name auto completion part, this is the only feature preventing me from never using terminal again. Currently needing to use an extra get pod, service... command just to get the pod name to be used in the log or describe command is inconvenient.

@rubengmurray
Copy link

This needs to happen. It's my only complaint with warp.

@mschaefer-gresham
Copy link

mschaefer-gresham commented Jul 3, 2024

Please add this feature and feature request 3978 at the same time. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature requests Feature Requests
Projects
None yet
Development

No branches or pull requests