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

support fish shell #5

Open
skyfaller opened this issue May 27, 2020 · 1 comment
Open

support fish shell #5

skyfaller opened this issue May 27, 2020 · 1 comment

Comments

@skyfaller
Copy link

What would be required to support fish?

I would like to add fish completions to Caddy. Since they are using completely to generate their shell completion scripts, it appears that I need to add fish support to completely.

I have no Javascript experience, but I have been tinkering with fish, so I might be able to help a bit.

@fvictorio
Copy link
Owner

Hi @skyfaller!

So, the idea of completely is to have a separate package for each shell. So the first step would be to add a fish-generator package.

Then you need to create a template.fish with the template for the completion script. (I don't know anything about how fish completion works, so I'm assuming that generating a file will be enough; let me know if that's not the case.) The templates use handlebars.

If you give me a very minimal example of a fish completion I can generate the boilerplate and push it to a branch and you can take it from there. For example, just a completion script for the example in the readme: a my-command command with a single positional arg draw and then a --color flag that can be either blue, green or red.

I also really need to write some documentation on how to setup the project for contributing. It's not that hard but there are some necessary steps that need to be done.

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

No branches or pull requests

2 participants