summaryrefslogtreecommitdiff
path: root/extra/source/bash-completion/patches/0003-tar-Fix-GNU-tar-help-output-parsing-regex-fixes-15.patch
diff options
context:
space:
mode:
Diffstat (limited to 'extra/source/bash-completion/patches/0003-tar-Fix-GNU-tar-help-output-parsing-regex-fixes-15.patch')
-rw-r--r--extra/source/bash-completion/patches/0003-tar-Fix-GNU-tar-help-output-parsing-regex-fixes-15.patch25
1 files changed, 25 insertions, 0 deletions
diff --git a/extra/source/bash-completion/patches/0003-tar-Fix-GNU-tar-help-output-parsing-regex-fixes-15.patch b/extra/source/bash-completion/patches/0003-tar-Fix-GNU-tar-help-output-parsing-regex-fixes-15.patch
new file mode 100644
index 00000000..621ccd12
--- /dev/null
+++ b/extra/source/bash-completion/patches/0003-tar-Fix-GNU-tar-help-output-parsing-regex-fixes-15.patch
@@ -0,0 +1,25 @@
+From 0b7189d4eee4597e11cab02e6b4dcae488db5ca8 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Ville=20Skytt=C3=A4?= <ville.skytta@iki.fi>
+Date: Wed, 16 Mar 2016 12:28:29 +0200
+Subject: [PATCH 3/5] tar: Fix GNU tar help output parsing regex, fixes #15
+
+---
+ completions/tar | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/completions/tar b/completions/tar
+index 6e4c74c..0a5f588 100644
+--- a/completions/tar
++++ b/completions/tar
+@@ -105,7 +105,7 @@ __gnu_tar_parse_help()
+ # or more options separated by ', ' separator string. We are matching
+ # like this then: ^<spaces>(<separator>?<option>)+<whatever>$
+ if [[ "$line" =~ \
+- ^[[:blank:]]{1,10}(((,[[:blank:]])?(--?([\]\[a-zA-Z0-9?-=]+))(,[[:space:]])?)+).*$ ]]; then
++ ^[[:blank:]]{1,10}(((,[[:blank:]])?(--?([\]\[a-zA-Z0-9?=-]+))(,[[:space:]])?)+).*$ ]]; then
+
+ line=${BASH_REMATCH[1]}
+ str="${line//,/ }"
+--
+2.7.2
+