mirror of
https://github.com/fish-shell/fish-shell
synced 2024-11-10 07:04:29 +00:00
Move __fish_complete_svn_diff into the completion script
This commit is contained in:
parent
965b142acd
commit
a361cde1df
11 changed files with 27 additions and 67 deletions
5
po/de.po
5
po/de.po
|
@ -67198,11 +67198,6 @@ msgstr ""
|
|||
msgid "Complete using files"
|
||||
msgstr "Saloppe Einhäng-Optionen tolerieren"
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_svn_diff.fish:1
|
||||
#, fuzzy
|
||||
msgid "Complete \"svn diff\" arguments"
|
||||
msgstr "Anzahl der Argumente zählen"
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1
|
||||
#, fuzzy
|
||||
msgid "Print list host-names with user@"
|
||||
|
|
4
po/en.po
4
po/en.po
|
@ -66549,10 +66549,6 @@ msgstr ""
|
|||
msgid "Complete using files"
|
||||
msgstr "Complete using path"
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_svn_diff.fish:1
|
||||
msgid "Complete \"svn diff\" arguments"
|
||||
msgstr "Complete “svn diff” arguments"
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1
|
||||
#, fuzzy
|
||||
msgid "Print list host-names with user@"
|
||||
|
|
4
po/fr.po
4
po/fr.po
|
@ -65525,10 +65525,6 @@ msgstr ""
|
|||
msgid "Complete using files"
|
||||
msgstr "Compléter en utilisant les fichiers"
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_svn_diff.fish:1
|
||||
msgid "Complete \"svn diff\" arguments"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1
|
||||
#, fuzzy
|
||||
msgid "Print list host-names with user@"
|
||||
|
|
4
po/nb.po
4
po/nb.po
|
@ -61987,10 +61987,6 @@ msgstr ""
|
|||
msgid "Complete using files"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_svn_diff.fish:1
|
||||
msgid "Complete \"svn diff\" arguments"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1
|
||||
msgid "Print list host-names with user@"
|
||||
msgstr ""
|
||||
|
|
4
po/nn.po
4
po/nn.po
|
@ -61987,10 +61987,6 @@ msgstr ""
|
|||
msgid "Complete using files"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_svn_diff.fish:1
|
||||
msgid "Complete \"svn diff\" arguments"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1
|
||||
msgid "Print list host-names with user@"
|
||||
msgstr ""
|
||||
|
|
4
po/pl.po
4
po/pl.po
|
@ -62576,10 +62576,6 @@ msgstr ""
|
|||
msgid "Complete using files"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_svn_diff.fish:1
|
||||
msgid "Complete \"svn diff\" arguments"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1
|
||||
msgid "Print list host-names with user@"
|
||||
msgstr ""
|
||||
|
|
|
@ -67668,11 +67668,6 @@ msgstr ""
|
|||
msgid "Complete using files"
|
||||
msgstr "Tolerate sloppy mount options"
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_svn_diff.fish:1
|
||||
#, fuzzy
|
||||
msgid "Complete \"svn diff\" arguments"
|
||||
msgstr "Count the number of arguments"
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1
|
||||
#, fuzzy
|
||||
msgid "Print list host-names with user@"
|
||||
|
|
4
po/sv.po
4
po/sv.po
|
@ -61991,10 +61991,6 @@ msgstr ""
|
|||
msgid "Complete using files"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_svn_diff.fish:1
|
||||
msgid "Complete \"svn diff\" arguments"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1
|
||||
msgid "Print list host-names with user@"
|
||||
msgstr ""
|
||||
|
|
|
@ -62536,11 +62536,6 @@ msgstr ""
|
|||
msgid "Complete using files"
|
||||
msgstr ""
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_svn_diff.fish:1
|
||||
#, fuzzy
|
||||
msgid "Complete \"svn diff\" arguments"
|
||||
msgstr "参数的个数的计数"
|
||||
|
||||
#: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1
|
||||
msgid "Print list host-names with user@"
|
||||
msgstr ""
|
||||
|
|
|
@ -1,3 +1,29 @@
|
|||
function __fish_complete_svn_diff --description 'Complete "svn diff" arguments'
|
||||
set -l cmdl (commandline -cop)
|
||||
#set -l cmdl svn diff --diff-cmd diff --extensions '-a -b'
|
||||
set -l diff diff
|
||||
set -l args
|
||||
while set -q cmdl[1]
|
||||
switch $cmdl[1]
|
||||
case --diff-cmd
|
||||
if set -q cmdl[2]
|
||||
set diff $cmdl[2]
|
||||
set -e cmd[2]
|
||||
end
|
||||
|
||||
case --extensions
|
||||
if set -q cmdl[2]
|
||||
set args $cmdl[2]
|
||||
set -e cmdl[2]
|
||||
end
|
||||
end
|
||||
set -e cmdl[1]
|
||||
end
|
||||
set -l token (commandline -cpt)
|
||||
complete -C"$diff $args $token"
|
||||
|
||||
end
|
||||
|
||||
function _svn_cmpl_ -d 'Make a completion for a subcommand' --no-scope-shadowing --argument-names subcommand
|
||||
set -e argv[1]
|
||||
complete -c svn -n "__fish_seen_subcommand_from $subcommand" $argv
|
||||
|
@ -166,9 +192,7 @@ for cmd in $blame $diff $log $merge
|
|||
_svn_cmpl_ $cmd -l extensions -s x -d 'Ignore all whitespace' -xa '-w --ignore-all-space'
|
||||
_svn_cmpl_ $cmd -l extensions -s x -d 'Ignore eol style' -xa '-w --ignore-eol-style'
|
||||
_svn_cmpl_ $cmd -l extensions -s x -d 'Show C function name' -xa '-p --show-c-function'
|
||||
|
||||
# Next completion doesn't work, since fish doesn't respect -x key
|
||||
#_svn_cmpl_ $cmd -l extensions -n '__fish_seen_subcommand_from --diff-cmd' -xa '(__fish_complete_svn_diff)'
|
||||
_svn_cmpl_ $cmd -l extensions -n '__fish_seen_subcommand_from --diff-cmd' -xa '(__fish_complete_svn_diff)'
|
||||
end
|
||||
|
||||
for cmd in $cleanup $merge $switch $update
|
||||
|
|
|
@ -1,25 +0,0 @@
|
|||
function __fish_complete_svn_diff --description 'Complete "svn diff" arguments'
|
||||
set -l cmdl (commandline -cop)
|
||||
#set -l cmdl svn diff --diff-cmd diff --extensions '-a -b'
|
||||
set -l diff diff
|
||||
set -l args
|
||||
while set -q cmdl[1]
|
||||
switch $cmdl[1]
|
||||
case --diff-cmd
|
||||
if set -q cmdl[2]
|
||||
set diff $cmdl[2]
|
||||
set -e cmd[2]
|
||||
end
|
||||
|
||||
case --extensions
|
||||
if set -q cmdl[2]
|
||||
set args $cmdl[2]
|
||||
set -e cmdl[2]
|
||||
end
|
||||
end
|
||||
set -e cmdl[1]
|
||||
end
|
||||
set -l token (commandline -cpt)
|
||||
complete -C"$diff $args $token"
|
||||
|
||||
end
|
Loading…
Reference in a new issue