diff --git a/po/de.po b/po/de.po index 7e83305d4..3cf1f84bd 100644 --- a/po/de.po +++ b/po/de.po @@ -3603,14 +3603,6 @@ msgstr "" msgid "or the file was empty" msgstr "Nicht vorhandene Dateien als leer behandeln" -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:2 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:3 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:4 -#: /tmp/fish/explicit/share/functions/__fish_complete_unrar.fish:1 -msgid "%s\\tArchived file\\n" -msgstr "" - #: /tmp/fish/explicit/share/functions/__fish_complete_zfs_ro_properties.fish:3 #, fuzzy msgid "Achieved compression ratio" @@ -67211,11 +67203,6 @@ msgstr "Saloppe Einhäng-Optionen tolerieren" msgid "Complete \"svn diff\" arguments" msgstr "Anzahl der Argumente zählen" -#: /tmp/fish/implicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/implicit/share/functions/__fish_complete_unrar.fish:1 -msgid "Peek inside of archives and list all files" -msgstr "" - #: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1 #, fuzzy msgid "Print list host-names with user@" diff --git a/po/en.po b/po/en.po index f1474f970..9d93c2a78 100644 --- a/po/en.po +++ b/po/en.po @@ -3442,14 +3442,6 @@ msgstr "" msgid "or the file was empty" msgstr "Treat absent files as empty" -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:2 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:3 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:4 -#: /tmp/fish/explicit/share/functions/__fish_complete_unrar.fish:1 -msgid "%s\\tArchived file\\n" -msgstr "%s\\tArchived file\\n" - #: /tmp/fish/explicit/share/functions/__fish_complete_zfs_ro_properties.fish:3 msgid "Achieved compression ratio" msgstr "Achieved compression ratio" @@ -66561,11 +66553,6 @@ msgstr "Complete using path" msgid "Complete \"svn diff\" arguments" msgstr "Complete “svn diff” arguments" -#: /tmp/fish/implicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/implicit/share/functions/__fish_complete_unrar.fish:1 -msgid "Peek inside of archives and list all files" -msgstr "" - #: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1 #, fuzzy msgid "Print list host-names with user@" diff --git a/po/fr.po b/po/fr.po index c3c90cc9a..d8992d1bd 100644 --- a/po/fr.po +++ b/po/fr.po @@ -3623,14 +3623,6 @@ msgstr "" msgid "or the file was empty" msgstr "ou le fichier était vide" -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:2 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:3 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:4 -#: /tmp/fish/explicit/share/functions/__fish_complete_unrar.fish:1 -msgid "%s\\tArchived file\\n" -msgstr "%s\\tFichier archivé\\n" - #: /tmp/fish/explicit/share/functions/__fish_complete_zfs_ro_properties.fish:3 msgid "Achieved compression ratio" msgstr "Taux de compression attein" @@ -65537,11 +65529,6 @@ msgstr "Compléter en utilisant les fichiers" msgid "Complete \"svn diff\" arguments" msgstr "" -#: /tmp/fish/implicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/implicit/share/functions/__fish_complete_unrar.fish:1 -msgid "Peek inside of archives and list all files" -msgstr "" - #: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1 #, fuzzy msgid "Print list host-names with user@" diff --git a/po/nb.po b/po/nb.po index 52e244788..e16759f7d 100644 --- a/po/nb.po +++ b/po/nb.po @@ -3377,14 +3377,6 @@ msgstr "" msgid "or the file was empty" msgstr "" -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:2 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:3 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:4 -#: /tmp/fish/explicit/share/functions/__fish_complete_unrar.fish:1 -msgid "%s\\tArchived file\\n" -msgstr "" - #: /tmp/fish/explicit/share/functions/__fish_complete_zfs_ro_properties.fish:3 msgid "Achieved compression ratio" msgstr "" @@ -61999,11 +61991,6 @@ msgstr "" msgid "Complete \"svn diff\" arguments" msgstr "" -#: /tmp/fish/implicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/implicit/share/functions/__fish_complete_unrar.fish:1 -msgid "Peek inside of archives and list all files" -msgstr "" - #: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1 msgid "Print list host-names with user@" msgstr "" diff --git a/po/nn.po b/po/nn.po index 1241996d8..1795dd448 100644 --- a/po/nn.po +++ b/po/nn.po @@ -3377,14 +3377,6 @@ msgstr "" msgid "or the file was empty" msgstr "" -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:2 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:3 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:4 -#: /tmp/fish/explicit/share/functions/__fish_complete_unrar.fish:1 -msgid "%s\\tArchived file\\n" -msgstr "" - #: /tmp/fish/explicit/share/functions/__fish_complete_zfs_ro_properties.fish:3 msgid "Achieved compression ratio" msgstr "" @@ -61999,11 +61991,6 @@ msgstr "" msgid "Complete \"svn diff\" arguments" msgstr "" -#: /tmp/fish/implicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/implicit/share/functions/__fish_complete_unrar.fish:1 -msgid "Peek inside of archives and list all files" -msgstr "" - #: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1 msgid "Print list host-names with user@" msgstr "" diff --git a/po/pl.po b/po/pl.po index 37c89891d..de88612c7 100644 --- a/po/pl.po +++ b/po/pl.po @@ -3435,14 +3435,6 @@ msgstr "" msgid "or the file was empty" msgstr "" -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:2 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:3 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:4 -#: /tmp/fish/explicit/share/functions/__fish_complete_unrar.fish:1 -msgid "%s\\tArchived file\\n" -msgstr "" - #: /tmp/fish/explicit/share/functions/__fish_complete_zfs_ro_properties.fish:3 msgid "Achieved compression ratio" msgstr "" @@ -62588,11 +62580,6 @@ msgstr "" msgid "Complete \"svn diff\" arguments" msgstr "" -#: /tmp/fish/implicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/implicit/share/functions/__fish_complete_unrar.fish:1 -msgid "Peek inside of archives and list all files" -msgstr "" - #: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1 msgid "Print list host-names with user@" msgstr "" diff --git a/po/pt_BR.po b/po/pt_BR.po index 4e3ce749c..06a7ee48d 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -3578,14 +3578,6 @@ msgstr "" msgid "or the file was empty" msgstr "Treat absent files as empty" -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:2 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:3 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:4 -#: /tmp/fish/explicit/share/functions/__fish_complete_unrar.fish:1 -msgid "%s\\tArchived file\\n" -msgstr "" - #: /tmp/fish/explicit/share/functions/__fish_complete_zfs_ro_properties.fish:3 #, fuzzy msgid "Achieved compression ratio" @@ -67681,11 +67673,6 @@ msgstr "Tolerate sloppy mount options" msgid "Complete \"svn diff\" arguments" msgstr "Count the number of arguments" -#: /tmp/fish/implicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/implicit/share/functions/__fish_complete_unrar.fish:1 -msgid "Peek inside of archives and list all files" -msgstr "" - #: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1 #, fuzzy msgid "Print list host-names with user@" diff --git a/po/sv.po b/po/sv.po index ff9d90655..c1dccba8e 100644 --- a/po/sv.po +++ b/po/sv.po @@ -3381,14 +3381,6 @@ msgstr "" msgid "or the file was empty" msgstr "" -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:2 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:3 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:4 -#: /tmp/fish/explicit/share/functions/__fish_complete_unrar.fish:1 -msgid "%s\\tArchived file\\n" -msgstr "" - #: /tmp/fish/explicit/share/functions/__fish_complete_zfs_ro_properties.fish:3 msgid "Achieved compression ratio" msgstr "" @@ -62003,11 +61995,6 @@ msgstr "" msgid "Complete \"svn diff\" arguments" msgstr "" -#: /tmp/fish/implicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/implicit/share/functions/__fish_complete_unrar.fish:1 -msgid "Peek inside of archives and list all files" -msgstr "" - #: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1 msgid "Print list host-names with user@" msgstr "" diff --git a/po/zh_CN.po b/po/zh_CN.po index 8a09b58ee..14bd2b644 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -3419,14 +3419,6 @@ msgstr "" msgid "or the file was empty" msgstr "" -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:2 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:3 -#: /tmp/fish/explicit/share/functions/__fish_complete_tar.fish:4 -#: /tmp/fish/explicit/share/functions/__fish_complete_unrar.fish:1 -msgid "%s\\tArchived file\\n" -msgstr "" - #: /tmp/fish/explicit/share/functions/__fish_complete_zfs_ro_properties.fish:3 msgid "Achieved compression ratio" msgstr "" @@ -62549,11 +62541,6 @@ msgstr "" msgid "Complete \"svn diff\" arguments" msgstr "参数的个数的计数" -#: /tmp/fish/implicit/share/functions/__fish_complete_tar.fish:1 -#: /tmp/fish/implicit/share/functions/__fish_complete_unrar.fish:1 -msgid "Peek inside of archives and list all files" -msgstr "" - #: /tmp/fish/implicit/share/functions/__fish_complete_user_at_hosts.fish:1 msgid "Print list host-names with user@" msgstr "" diff --git a/share/completions/tar.fish b/share/completions/tar.fish index 122a4ded0..abeeb478d 100644 --- a/share/completions/tar.fish +++ b/share/completions/tar.fish @@ -1,5 +1,23 @@ +function __fish_complete_tar -d "Peek inside of archives and list all files" + set -l args (commandline -poc) + while count $args >/dev/null + switch $args[1] + case '-*f' '--file' + set -e args[1] + if test -f $args[1] + set -l file_list (tar -atf $args[1] 2> /dev/null) + if test -n "$file_list" + printf (_ "%s\tArchived file\n") $file_list + end + return + end + case '*' + set -e args[1] + continue + end + end +end -# Peek inside of archives and list all files complete -c tar -a "(__fish_complete_tar)" complete -c tar -s A -l catenate -d "Append archive to archive" diff --git a/share/functions/__fish_complete_tar.fish b/share/functions/__fish_complete_tar.fish deleted file mode 100644 index a44620e58..000000000 --- a/share/functions/__fish_complete_tar.fish +++ /dev/null @@ -1,21 +0,0 @@ - -function __fish_complete_tar -d "Peek inside of archives and list all files" - - set -l args (commandline -poc) - while count $args >/dev/null - switch $args[1] - case '-*f' '--file' - set -e args[1] - if test -f $args[1] - set -l file_list (tar -atf $args[1] 2> /dev/null) - if test -n "$file_list" - printf (_ "%s\tArchived file\n") $file_list - end - return - end - case '*' - set -e args[1] - continue - end - end -end