Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Missing completions #652

Jan 20, 2022 · 106 comments · 43 replies
Discussion options

See #654

You must be logged in to vote

Replies: 106 comments 43 replies

Comment options

Support Kubectl

From @uhinze via #129

I'm relying heavily on kubectl in my day-to-day work. I normally use iTerm2 with oh-my-zsh with the kubectl plugin, which also gives me a k alias for kubectl and a bunch of others (like keti for kubectl exec -ti) which are super helpful. This would be awesome to have replicated in some way in Warp.
To explain a bit for non k8s users, when you're operating stuff on Kubernetes you need kubectl all the time. When you're deep into troubleshooting an issue, you may issue the command like 20/30/40 times in a row. So every keystroke less is good :-) the oh-my-zsh plugin solves this pretty well I think.
Maybe for Warp, this just means also autocompleting after resolving aliases (and not just for the blank kubectl command).

You must be logged in to vote
3 replies
Comment options

From @joscdk via #129

Would like to add to this, for example by adding something like kube-ps1, so being able to show current K8s context and namespace just like git info.

Kube-ps1: https://github.com/jonmosco/kube-ps1

Comment options

From Nirlep via Discord: https://discord.com/channels/851854972600451112/932083406840410152/932802271367008257

@Elvis I can see that but what I was asking is... kubectl completion for kubernetes resources as well.

For example: kubectl describe pod - right now I can't auto/tab complete command after "describe" in Warp. It works in iTerm.

Comment options

Comment options

Tab completion for Azure CLI

From @robinhultman via #244

Describe the solution you'd like?

I would love to have tab completion for the Azure CLI

Is your feature request related to a problem? Please describe.

No response

Additional context

No response

You must be logged in to vote
2 replies
Comment options

second this plus awscli pls

Comment options

same!

Comment options

Support MacPorts

From @Gregory-Gelfond via #343

Describe the solution you'd like?

Ideally we could have support for completions of `port` and `brew` provided by the [MacPorts](https://www.macports.org) and [HomeBrew](https://brew.sh) package management projects respectively.

Is your feature request related to a problem? Please describe.

No response

Additional context

No response

You must be logged in to vote
2 replies
Comment options

From @Gregory-Gelfond

Maybe even parse a command's manpage to learn it's command completions and options.

Comment options

we added brew but haven't added macport yet

Comment options

You must be logged in to vote
0 replies
Comment options

image
image

Figure 1 shows a screenshot in Kitty where I was able to list all the k8s CRDs starting with "po" using the "Tab" key. As shown in Figure 2, I can't do that in Warp, only "Postman" is listed (a folder in the current directory).

I wonder if I got something wrong that caused such a difference and imperfection

You must be logged in to vote
1 reply
Comment options

+1 to this, having the same issue

Comment options

Would like to have Oracle's SQLcl and OCI CLI

You must be logged in to vote
0 replies
Comment options

Vim / Neovim

> cat /opt/homebrew/share/fish/completions/nvim.fish
complete -c nvim -w vim
# -> mostly the same 🤷🏼‍♂️
You must be logged in to vote
0 replies
Comment options

Some of my completions are only working after I run reload.

For example, knative cli and azure cli each have this issue.


Relevant .zshrc config for knative cli

# Add zsh completions for `kn` (knati`ve` cli)
source <(kn completion zsh)
compdef _kn kn
kn completion zsh output
#compdef _kn kn
# zsh completion for kn -*- shell-script -*-
__kn_debug()
{
 local file="$BASH_COMP_DEBUG_FILE"
 if [[ -n ${file} ]]; then
 echo "$*" >> "${file}"
 fi
}
_kn()
{
 local shellCompDirectiveError=1
 local shellCompDirectiveNoSpace=2
 local shellCompDirectiveNoFileComp=4
 local shellCompDirectiveFilterFileExt=8
 local shellCompDirectiveFilterDirs=16
 local lastParam lastChar flagPrefix requestComp out directive comp lastComp noSpace
 local -a completions
 __kn_debug "\n========= starting completion logic =========="
 __kn_debug "CURRENT: ${CURRENT}, words[*]: ${words[*]}"
 # The user could have moved the cursor backwards on the command-line.
 # We need to trigger completion from the $CURRENT location, so we need
 # to truncate the command-line ($words) up to the $CURRENT location.
 # (We cannot use $CURSOR as its value does not work when a command is an alias.)
 words=("${=words[1,CURRENT]}")
 __kn_debug "Truncated words[*]: ${words[*]},"
 lastParam=${words[-1]}
 lastChar=${lastParam[-1]}
 __kn_debug "lastParam: ${lastParam}, lastChar: ${lastChar}"
 # For zsh, when completing a flag with an = (e.g., kn -n=<TAB>)
 # completions must be prefixed with the flag
 setopt local_options BASH_REMATCH
 if [[ "${lastParam}" =~ '-.*=' ]]; then
 # We are dealing with a flag with an =
 flagPrefix="-P ${BASH_REMATCH}"
 fi
 # Prepare the command to obtain completions
 requestComp="${words[1]} __complete ${words[2,-1]}"
 if [ "${lastChar}" = "" ]; then
 # If the last parameter is complete (there is a space following it)
 # We add an extra empty parameter so we can indicate this to the go completion code.
 __kn_debug "Adding extra empty parameter"
 requestComp="${requestComp} \"\""
 fi
 __kn_debug "About to call: eval ${requestComp}"
 # Use eval to handle any environment variables and such
 out=$(eval ${requestComp} 2>/dev/null)
 __kn_debug "completion output: ${out}"
 # Extract the directive integer following a : from the last line
 local lastLine
 while IFS='\n' read -r line; do
 lastLine=${line}
 done < <(printf "%s\n" "${out[@]}")
 __kn_debug "last line: ${lastLine}"
 if [ "${lastLine[1]}" = : ]; then
 directive=${lastLine[2,-1]}
 # Remove the directive including the : and the newline
 local suffix
 (( suffix=${#lastLine}+2))
 out=${out[1,-$suffix]}
 else
 # There is no directive specified. Leave $out as is.
 __kn_debug "No directive found. Setting do default"
 directive=0
 fi
 __kn_debug "directive: ${directive}"
 __kn_debug "completions: ${out}"
 __kn_debug "flagPrefix: ${flagPrefix}"
 if [ $((directive & shellCompDirectiveError)) -ne 0 ]; then
 __kn_debug "Completion received error. Ignoring completions."
 return
 fi
 while IFS='\n' read -r comp; do
 if [ -n "$comp" ]; then
 # If requested, completions are returned with a description.
 # The description is preceded by a TAB character.
 # For zsh's _describe, we need to use a : instead of a TAB.
 # We first need to escape any : as part of the completion itself.
 comp=${comp//:/\\:}
 local tab=$(printf '\t')
 comp=${comp//$tab/:}
 __kn_debug "Adding completion: ${comp}"
 completions+=${comp}
 lastComp=$comp
 fi
 done < <(printf "%s\n" "${out[@]}")
 if [ $((directive & shellCompDirectiveNoSpace)) -ne 0 ]; then
 __kn_debug "Activating nospace."
 noSpace="-S ''"
 fi
 if [ $((directive & shellCompDirectiveFilterFileExt)) -ne 0 ]; then
 # File extension filtering
 local filteringCmd
 filteringCmd='_files'
 for filter in ${completions[@]}; do
 if [ ${filter[1]} != '*' ]; then
 # zsh requires a glob pattern to do file filtering
 filter="\*.$filter"
 fi
 filteringCmd+=" -g $filter"
 done
 filteringCmd+=" ${flagPrefix}"
 __kn_debug "File filtering command: $filteringCmd"
 _arguments '*:filename:'"$filteringCmd"
 elif [ $((directive & shellCompDirectiveFilterDirs)) -ne 0 ]; then
 # File completion for directories only
 local subDir
 subdir="${completions[1]}"
 if [ -n "$subdir" ]; then
 __kn_debug "Listing directories in $subdir"
 pushd "${subdir}" >/dev/null 2>&1
 else
 __kn_debug "Listing directories in ."
 fi
 local result
 _arguments '*:dirname:_files -/'" ${flagPrefix}"
 result=$?
 if [ -n "$subdir" ]; then
 popd >/dev/null 2>&1
 fi
 return $result
 else
 __kn_debug "Calling _describe"
 if eval _describe "completions" completions $flagPrefix $noSpace; then
 __kn_debug "_describe found some completions"
 # Return the success of having called _describe
 return 0
 else
 __kn_debug "_describe did not find completions."
 __kn_debug "Checking if we should do file completion."
 if [ $((directive & shellCompDirectiveNoFileComp)) -ne 0 ]; then
 __kn_debug "deactivating file completion"
 # We must return an error code here to let zsh know that there were no
 # completions found by _describe; this is what will trigger other
 # matching algorithms to attempt to find completions.
 # For example zsh can match letters in the middle of words.
 return 1
 else
 # Perform file completion
 __kn_debug "Activating file completion"
 # We must return the result of this command, so it must be the
 # last command, or else we must store its result to return it.
 _arguments '*:filename:_files'" ${flagPrefix}"
 fi
 fi
 fi
}
# don't run the completion function when being source-ed or eval-ed
if [ "$funcstack[1]" = "_kn" ]; then
	_kn
fi
You must be logged in to vote
0 replies
Comment options

I have a custom command and have setup completion for it using COMPREPLY
The completion works fine on normal terminal, but doesn't work on Warp. Does this require additional configuration to work?

You must be logged in to vote
0 replies
Comment options

Should add support for these:
https://github.com/posener/complete/tree/master

You must be logged in to vote
0 replies
Comment options

Hi, I would love to see 1Password CLI 2 tab completion.

I use op a lot, so a feature like this would be great.

You must be logged in to vote
2 replies
Comment options

I've added support for this to Fig now, so when the completions are updated in Warp you'll get op completions!

Comment options

Completions in warp are updated now, new op completions available!

Comment options

I would love to see fuzzy auto-complete supported as it is a feature I use extensively in my shell and is my current dealbreaker for using Warp.dev. For example let's say there's a directory called "github.com" the command cd hub<tab> should auto-complete to cd github.com.

You must be logged in to vote
0 replies
Comment options

スクリーンショット 2022年05月19日 9 12 40

スクリーンショット 2022年05月19日 9 13 28

With the default font (Hack), the history is displayed with the ↑ command, but with other fonts, the history display is blank.
We have checked a number of fonts, but the same phenomenon occurs in all of them.
The attached image shows Lantighe TC.

You must be logged in to vote
0 replies
Comment options

The AI command search is fantastic, but I have a suggestion to possibly improve it.

If I type "compile this project" in a Rust project folder (cargo), it tries to build a java program. If I type "compile this rust project" then it works. The AI could detect the existence of common project definition files (cargo, cmake, gradle, npm, yarn, maven, etc) and use it as a hint.

You must be logged in to vote
2 replies
Comment options

thats not how ai works

Comment options

@mickeyperlstein Actually, what @ricardopieper is suggesting could definitely work. Since Warp has context info about the current working directory, it could actually grab all file(type)s on that directory and pass that information into the prompt for the LLM. So even a basic question like Compile this would in turn be transformed to the following prompt (by Warp)

Compile this
For some context, here are the files in my current working directory: 
- Cargo.toml
- Cargo.lock
- .gitignore
- build.rs
- READM.md

As an example, I ran this with ChatGPT and got the following response:

Show answer

I'm sorry, but as an AI language model, I don't have the capability to directly compile code or interact with your local file system. However, I can provide you with some general information about compilation and the file types you mentioned.

  • Cargo.toml: This file is used in Rust programming language projects and contains metadata about the project and its dependencies.
  • Cargo.lock: This file is automatically generated by Cargo, the package manager for Rust, and it locks the version of dependencies used in the project to ensure consistency across different environments.
  • .gitignore: This file is used with version control systems like Git and specifies which files and directories should be ignored and not tracked by the version control system.
  • build.rs: This file is a build script used in Rust projects to perform pre-build tasks or set up the build environment.
  • README.md: This is a Markdown file commonly used to provide documentation and information about the project.

If you have a Rust project and want to compile it, you can use the cargo command in your terminal. Make sure you have Rust and Cargo installed on your system. Then navigate to your project directory in the terminal and run:

cargo build

This command will compile the project and its dependencies. If there are no errors, the executable should be located in the target/debug/ directory (or target/release/ for a release build).

Keep in mind that I can only provide general guidance and cannot perform any actions on your specific environment or code. If you encounter any issues or need further assistance, please provide more details, and I'll be glad to help!

Comment options

can choose a font but can not chose a regular one or a bond one , some font's bond is a disaster

You must be logged in to vote
0 replies
Comment options

If possible, add oc (openshift-client) which is very close to kubectl

You must be logged in to vote
0 replies
Comment options

just command runner https://github.com/casey/just

It supports completions out of the box (of the commands you have defined in an individual directory) which they outline in their documentation - https://just.systems/man/en/shell-completion-scripts.html

It works fine in zsh and iTerm2, I just can't get it to work with Warp since it seems like Warp doesn't support ZSH completions.

You must be logged in to vote
0 replies
Comment options

I wanted to mention that for example kubecm completion also not works.

Tool: https://kubecm.cloud
OS: macOS
Shell: omz

Works in iTerm2 like a charm

You must be logged in to vote
0 replies
Comment options

Not sure if this is the proper place...but a suggestion/request for git autocomplete:

If I type git add . to add everything at once, autocomplete suggests a file. Hitting 'enter' then selects that file. Is there anyway to have . as the first suggestion? I always end up pressing enter and just adding one file without realizing it...

You must be logged in to vote
0 replies
Comment options

CleanShot 2024年10月26日 at 00 37 31@2x

I have this config. Maybe it can help u

You must be logged in to vote
0 replies
Comment options

I would like to request completions for chezmoi, which is a well-known dotfiles manager.

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

Not sur if it's a local configuration problem or if it's not supported ... But as I enter npm run then I hit my autocomplete key ( Tab ) and I don't see the list of my npm scripts 😢

But I can see on the docs that npm autocompletion should be fully covered ... It doesn't include npm scripts ?

I wish it could hint me the list of the npm script in my package.json

{
 "name": "my-app",
 "private": true,
 "version": "0.0.1",
 "scripts": {
 "test": "ls -la",
 "build": "some command to build",
 "pretty": "npx prettier --write . \"!{dist,coverage}/**/*\"",
 },
}

(I'm on windows)

You must be logged in to vote
0 replies
Comment options

Hi,

Could you please help me add the DDEV tool?

https://github.com/ddev/ddev

You must be logged in to vote
0 replies
Comment options

Any news on supporting Bun? It's pretty popular, I need this as use on most of my projects now.

You must be logged in to vote
0 replies
Comment options

The sad thing is, Warp is very slow on updating auto complete on tools we use. I need an option to do this myself to not wait for anything — either add own tool, or extend existing if Warp doesn't do that (like update Bun with the most recent features). And sync it with iCloud or account settings. Just do it please.

You must be logged in to vote
2 replies
Comment options

Yeah, this is the reason an open source competitor to Warp will win if this is the posture. Closed source is no good here and there is very poor communication about this to the community. Communication can be improved by Warp by saying what the plans are to do about it, and when. They are having too much closed source communication about this. You can be closed source and still have open communication. But too often the closed source comes with closed communication.

Comment options

+1 to this. This is not just for public tools but also just uncommon, domain-specific or internal tools.

Comment options

Git-Spice

I'd specifically request that git-spice completions be added to Warp.

In General

I'd like Warp to honor installed shell completions for more niche tools. I can't see how it's feasible for Warp to have to manually track completions for every possible OSS tool under the sun.

You must be logged in to vote
1 reply
Comment options

I have a lot of custom shell functions with auto-completion and i can't use them on warp.

What about simply "checking" if _function exist when i typed function ?

For every custom auto-comp
complete -F _function function

It does not seem to work actually

Comment options

@elviskahoro any concrete plans to support community-driven specs?
perhaps even incorporate https://github.com/withfig/autocomplete ?

You must be logged in to vote
0 replies
Comment options

Any alternative terminal that integrated this?

You must be logged in to vote
0 replies
Comment options

Jujutsu (jj) completions would be very nice. Not having to type branch names is a godsend, plus each command uses a different version of from and to and remembering them is nigh impossible lol

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

AltStyle によって変換されたページ (->オリジナル) /