fix patch for bash 4.3
remove conclicting files for chsh provided by latest util-linux [release 2.1-5mamba;Sat Aug 02 2014]
This commit is contained in:
parent
f1f597fee8
commit
4f22a8e2ef
@ -1,12 +1,27 @@
|
||||
diff -Nru bash-completion-2.1.orig/bash_completion bash-completion-2.1/bash_completion
|
||||
--- bash-completion-2.1.orig/bash_completion 2013-04-05 10:55:51.000000000 +0000
|
||||
+++ bash-completion-2.1/bash_completion 2014-05-05 07:56:56.720101465 +0000
|
||||
@@ -707,7 +707,7 @@
|
||||
fi
|
||||
done
|
||||
|
||||
- [[ $cword -eq 0 ]] && return 1
|
||||
+ [[ $cword -le 0 ]] && return 1
|
||||
prev=${words[cword-1]}
|
||||
|
||||
[[ ${split-} ]] && _split_longopt && split=true
|
||||
--- bash_completion 2014-03-09 17:38:14 +0000
|
||||
+++ bash_completion 2014-03-13 23:26:44 +0000
|
||||
@@ -536,13 +536,23 @@
|
||||
# @param $2 Name of variable to return result to
|
||||
_quote_readline_by_ref()
|
||||
{
|
||||
- if [[ $1 == \'* ]]; then
|
||||
+ if [ -z "$1" ]; then
|
||||
+ # avoid quoting if empty
|
||||
+ printf -v $2 %s "$1"
|
||||
+ elif [[ $1 == \'* ]]; then
|
||||
# Leave out first character
|
||||
printf -v $2 %s "${1:1}"
|
||||
+ elif [[ $1 == ~* ]]; then
|
||||
+ # avoid escaping first ~
|
||||
+ printf -v $2 ~%q "${1:1}"
|
||||
else
|
||||
printf -v $2 %q "$1"
|
||||
fi
|
||||
|
||||
+ # Replace double escaping ( \\ ) by single ( \ )
|
||||
+ # This happens always when argument is already escaped at cmdline,
|
||||
+ # and passed to this function as e.g.: file\ with\ spaces
|
||||
+ [[ ${!2} == *\\* ]] && printf -v $2 %s "${1//\\\\/\\}"
|
||||
# If result becomes quoted like this: $'string', re-evaluate in order to
|
||||
# drop the additional quoting. See also: http://www.mail-archive.com/
|
||||
# bash-completion-devel@lists.alioth.debian.org/msg01942.html
|
@ -1,7 +1,7 @@
|
||||
### AUTOUPDATE-OFF: 0
|
||||
Name: bash-completion
|
||||
Version: 2.1
|
||||
Release: 4mamba
|
||||
Release: 5mamba
|
||||
Epoch: 1
|
||||
Summary: Programmable completion for bash
|
||||
Group: Applications/Shells
|
||||
@ -24,7 +24,7 @@ bash-completion is a collection of shell functions that take advantage of the pr
|
||||
%prep
|
||||
%setup -q
|
||||
#%patch -p1
|
||||
%patch1 -p1
|
||||
#%patch1 -p1
|
||||
|
||||
%build
|
||||
%configure
|
||||
@ -46,7 +46,7 @@ rm -f %{buildroot}%{_datadir}/bash-completion/completions/nmcli
|
||||
|
||||
# provided in util-linux
|
||||
rm -f %{buildroot}%{_datadir}/bash-completion/completions/\
|
||||
{cal,dmesg,eject,hexdump,ionice,hwclock,ionice,look,renice,rtcwake,su}
|
||||
{cal,chsh,dmesg,eject,hexdump,ionice,hwclock,ionice,look,renice,rtcwake,su}
|
||||
|
||||
%clean
|
||||
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
||||
@ -66,6 +66,10 @@ rm -f %{buildroot}%{_datadir}/bash-completion/completions/\
|
||||
#%doc CHANGES README
|
||||
|
||||
%changelog
|
||||
* Sat Aug 02 2014 Silvan Calarco <silvan.calarco@mambasoft.it> 2.1-5mamba
|
||||
- fix patch for bash 4.3
|
||||
- remove conclicting files for chsh provided by latest util-linux
|
||||
|
||||
* Mon May 05 2014 Silvan Calarco <silvan.calarco@mambasoft.it> 2.1-4mamba
|
||||
- patch against bash 4.3 (see https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=741479)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user