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

WIP: Add bash completion #721

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

Conversation

JoshuaWilkes
Copy link
Contributor

@JoshuaWilkes JoshuaWilkes commented Aug 5, 2024

What changed?

Fixes #579

Add some initial code to support bash completion following the guide here https://cli.urfave.org/v2/examples/bash-completions/

On Mac OS I install bash completion support using brew https://formulae.brew.sh/formula/bash-completion however this led me to an error with nosort I followed this guide https://rakhesh.com/mac/bash-complete-nosort-invalid-option-name/ to identify the completions that were causing this issue.
removing them from the folder made the error go away.

I'm on mac using bash 3.2

To get this working, we need to figure out exactly what the install steps and prerequisits are for bash complete to work on each platform and with which versions of bash.

We need to codify this, so thats generating the completion scripts and moving it to the correct location so that it gets loaded when bash starts.

In ZSH we had some extra behaviour for handling arguments and for assume, forcing no shell alias, this needs to be tested once we can get the completions to run in a dev environment.

Why?

How did you test it?

Potential risks

Is patch release candidate?

Link to relevant docs PRs

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

Successfully merging this pull request may close these issues.

Autocompletion for Bash
1 participant