mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-22 12:11:16 -03:00
completions/git: show url as description for remote completion
This commit is contained in:
@@ -62,6 +62,7 @@ New or improved bindings
|
||||
|
||||
Completions
|
||||
^^^^^^^^^^^
|
||||
- ``git`` completions now show the remote url as a description when completing remotes.
|
||||
|
||||
Improved terminal support
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
@@ -96,7 +96,9 @@ function __fish_git_refs
|
||||
end
|
||||
|
||||
function __fish_git_remotes
|
||||
__fish_git remote 2>/dev/null
|
||||
# Example of output parsed:
|
||||
# "remote.upstream.url git@github.com:fish-shell/fish-shell.git" -> "upstream\tgit@github.com:fish-shell/fish-shell.git"
|
||||
__fish_git config --get-regexp 'remote\.[a-z]+\.url' | string replace -rf 'remote\.(.*)\.url (.*)' '$1\t$2'
|
||||
end
|
||||
|
||||
function __fish_git_files
|
||||
|
||||
Reference in New Issue
Block a user