Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Register
  • Sign in
  • S slapos.core
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Merge requests 38
    • Merge requests 38
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Activity
  • Graph
  • Jobs
  • Commits
Collapse sidebar
  • nexedinexedi
  • slapos.core
  • Merge requests
  • !253

cli: fish shell completions

  • Review changes

  • Download
  • Patches
  • Plain diff
Merged Jérome Perrin requested to merge feat/shell_completions into master Oct 02, 2020
  • Overview 2
  • Commits 1
  • Pipelines 2
  • Changes 4

cliff complete command only supports bash, but fish offers much more user friendly completions.

cliff uses a pluggable system, but this where new shell completions can be registered, but the plugin (CompleteFish) can not access the command manager to get more details about options, since fish can also show help of suggestion, we want to access the help of each option to show this during suggestions. Also we want to make some more clever suggestions (for example slapos node start complete with services identifiers). For these reasons we need to register a command to replace the default complete command and can not achieve this with simply a cliff.formatter.completion entry point.

This can be installed with:

slapos complete > ~/.bash_completion.d/slapos
slapos complete --shell fish > ~/.config/fish/completions/slapos.fish
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: feat/shell_completions
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7