Skip to content

Clean up completions for Fossil - #2304

Merged
faho merged 1 commit into
fish-shell:masterfrom
bpollack:fossil
Aug 14, 2015
Merged

faho merged 1 commit into
fish-shell:masterfrom
bpollack:fossil

Conversation

@bpollack

Copy link
Copy Markdown
Contributor

There are two main problems in the existing Fossil autocompletion that this
patch solves:

  • Because Fossil lacks an alias system similar to those in Hg and Git,
    wrapper scripts are common, and aliasing them to fossil is also fairly
    common. The lack of the command fossil pattern in the completions script
    meant that the actual fossil command might not be called, but rather the
    alias. This problem has been fixed by introducing a __fish_fossil command,
    similar to the __fish_hg and __fish_git commands in those completion shells,
    that does this, and converting all explicit fossil calls in the completion
    script to use __fish_fossil instead
  • Because there's now a centralized location for calling Fossil, I also moved
    all of the repetitive stderr redirects that function.

This results in more robust and cleaner code.

There are two main problems in the existing Fossil autocompletion that this
patch solves:

  * Because Fossil lacks an alias system similar to those in Hg and Git,
    wrapper scripts are common, and aliasing them to `fossil` is also fairly
    common. The lack of the `command fossil` pattern in the completions script
    meant that the actual fossil command might not be called, but rather the
    alias. This problem has been fixed by introducing a __fish_fossil command,
    similar to the __fish_hg and __fish_git commands in those completion shells,
    that does this, and converting all explicit fossil calls in the completion
    script to use __fish_fossil instead
  * Because there's now a centralized location for calling Fossil, I also moved
    all of the repetitive stderr redirects that function.

This results in more robust and cleaner code.
faho added a commit that referenced this pull request Aug 14, 2015
Clean up completions for Fossil
@faho
faho merged commit 89c504d into fish-shell:master Aug 14, 2015
@faho

faho commented Aug 14, 2015

Copy link
Copy Markdown
Member

Yeah, looks good, merged. Thank you for your contribution.

@faho faho added this to the next-2.x milestone Sep 26, 2015
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Apr 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants