[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Quilt-dev] import improvement
From: |
Jean Delvare |
Subject: |
Re: [Quilt-dev] import improvement |
Date: |
Thu, 21 Dec 2006 15:29:58 +0100 |
Hi Holger,
On Thu, 21 Dec 2006 11:18:44 +0100, Holger Eitzenberger wrote:
> Thus saving some keystrokes...
>
> Signed-off-by: Holger Eitzenberger <address@hidden>
>
> Index: quilt/import.in
> ===================================================================
> RCS file: /sources/quilt/quilt/quilt/import.in,v
> retrieving revision 1.40
> diff -u -p -r1.40 import.in
> --- quilt/import.in 1 Jun 2006 10:01:21 -0000 1.40
> +++ quilt/import.in 21 Dec 2006 09:51:59 -0000
> @@ -19,7 +19,7 @@ fi
>
> usage()
> {
> - printf $"Usage: quilt import [-p num] [-P patch] [-f] [-d {o|a|n}]
> patchfile ...\n"
> + printf $"Usage: quilt import [-p num] [-P patch|dir] [-f] [-d {o|a|n}]
> patchfile ...\n"
> if [ x$1 = x-h ]
> then
> printf $"
> @@ -29,9 +29,10 @@ current top patch, and must be pushed af
> -p num
> Number of directory levels to strip when applying (default=1)
>
> --P patch
> - Patch filename to use inside quilt. This option can only be
> - used when importing a single patch.
> +-P patch|dir
> + Patch filename to use inside quilt. This option can only be used
> + when importing a single patch. If this is a directory the patch
> + will be added below this directory with the original name.
>
> -f Overwite/update existing patches.
>
> @@ -134,6 +135,10 @@ then
> exit 1
> fi
>
> +if [ -d "${QUILT_PATCHES:+$QUILT_PATCHES/}$opt_patch" ]; then
> + opt_patch="$opt_patch/${1##*/}"
> +fi
> +
> [ -n "$opt_strip" ] && patch_args="-p$opt_strip"
>
> for patch_file in "$@"
I wanted to give a try to your patch but it breaks the quilt test suite
(in import.test.) It seems to me that you assume that $opt_patch is
always set, while it may not be (-P is an option, not mandatory.)
Please rework your patch so that "quilt import" still works when -P
isn't used, make sure it passes the test suite, and resubmit.
Thanks,
--
Jean Delvare