quilt/grep-support-spaces.patch
Jean Delvare 73a1d19a84 - update to 0.50
o Obsoletes fix-test-create-delete.diff.
  o Obsoletes hide-git-desc-error.diff.
  o Obsoletes mail-dont-use-equal-tilde.diff.
  o Obsoletes revert-should-not-hard-link.diff.
  o Obsoletes fix-fr-import-message.diff.
  o Obsoletes lzma-xz-support.patch, except expand part which was
    merged in expand.diff.
  o Obsoletes inspect-lzma-xz.patch.
  o Obsoletes fix-patch-version-detection.patch.
  o Obsoletes setup-add-fuzz-parameter.patch.
  o Obsoletes setup-support-reverse-patch.patch.
  o Obsoletes completion-revert.patch.
  o Obsoletes inspect-shell-syntax-errors.patch.
  o Obsoletes mail-fix-a-temporary-directory-leak.patch.
  o Too many upstream changes in 34 months to list.
- Add missing requires: findutils.
- Add recommends: xz.

OBS-URL: https://build.opensuse.org/package/show/devel:tools:scm/quilt?expand=0&rev=37
2011-12-06 14:23:06 +00:00

29 lines
997 B
Diff

Subject: grep: Accept file names with spaces
This is a continuation of Yasushi SHOJI's initial work of fixing
support for file names with spaces. This time I fixed support in the
grep command. This is particularly important because the grep command
operates on all files in the work tree, even if they aren't touched
by any patch, so the chances that one of them has a space in its name
is greater. As before, no guarantee is made that all options are
covered, but this should be a good starting point.
Signed-off-by: Jean Delvare <jdelvare@suse.de>
---
quilt/grep.in | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- quilt-0.50.orig/quilt/grep.in
+++ quilt-0.50/quilt/grep.in
@@ -117,8 +117,8 @@ fi
find "${myargs[@]:-.}" \( \
-path "./$QUILT_PATCHES/*" -o \
-path "./$QUILT_PC/*" \) -prune -o \
- -type f -print \
-| xargs grep $opt_H "${args[@]}" \
+ -type f -print0 \
+| xargs -0 grep $opt_H "${args[@]}" \
| if [ ${#myargs[@]} -eq 0 ]; then
sed -e 's,^./,,'
else