Re: [Quilt-dev] Packages required to compile doc/main.tex

2020-05-14 Thread Martin Quinson
On Wed, May 13, 2020 at 07:08:49PM +0200, Ondřej Lysoněk wrote:
> Hi,
> 
> just throwing this information out there in case someone (future me, for
> example) finds it useful.
> 
> On Fedora, in order to compile doc/main.tex I needed to install the
> following packages:
> 
> texlive-latex texlive-subfigure texlive-metafont texlive-mfware
> texlive-cyrillic texlive-collection-langcyrillic texlive-cmap
> texlive-cm-super
> 
> It might be useful to document this somewhere.

I agree that this information is useful. In Debian, we compile the
page with hevea instead of texlive. This eases this problem, as the
hevea package is sufficient to build the page. I guess that it takes
care of pulling the needed dependencies, or something.

Likewise, (it seems that) running hevea once is enough to resolve all
the internal references.

Of course, the above information remains useful to the users of
texlive. I'm just a bit surprised by the need of texlive-cyrillic and
texlive-collection-langcyrillic. I could provide the corresponding
names for Debian and derivatives if you want. I have to do some tests
for that.

Thanks,
Mt

-- 
A language that doesn't affect the way you think about programming
is not worth knowing.  -- "Epigrams in Programming", by Alan J. Perlis


signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch] verbose error message when the serie file does not exist

2020-03-24 Thread Martin Quinson
Hello Jean,

On Tue, Mar 24, 2020 at 12:40:36PM +0100, Jean Delvare wrote:
> On Tue, 2020-03-24 at 11:08 +0100, Jean Delvare wrote:
> > I just pushed a new test case to cover this situation, so we won't
> > introduce that kind of regression.
> 
> By the way, this test case revealed a few inconsistencies. While most
> commands properly report "No series file found" if you are not in a
> quilt-managed tree, 3 commands diverge from this behavior:
> 
> * "quilt pop" reports "No patch removed" instead, which while not
> incorrect, is not consistent.
> 
> * "quilt series" report nothing. That's what Martin's patch aimed at
> fixing. I wonder it should report "No series file found" even when not
> in verbose mode? That would seem more consistent.
> 
> * "quilt snapshot" creates a .pc/ subdirectory and an empty .snap/
> directory there. Again while not fundamentally wrong, it doesn't seem
> particularly useful in the absence of a series file.
> 
> I'll look into fixing "pop" and "snapshot" to behave the same as all
> other commands.

Thanks for your investigation, Jean. quilt is lucky to have you: you
are doing a great job here. And I manage to mess even simple patches :)

IMHO, the only thing that is important to fix the former Debian bug is
that something is reported when using 'quilt series' out of a
quilt-managed tree. Reporting "No series file found" even when not in
verbose mode would be really perfect. I guess that whoever did that
patch back in 2014 wanted to reduce the divergence with upstream code,
thus reducing the visibility of the fix to verbose situations.

Thanks again,
Mt.

-- 
Success is not final, failure is not fatal:
it is the courage to continue that counts.-- Churchill (?)


signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch] verbose error message when the serie file does not exist

2020-03-23 Thread Martin Quinson
On Mon, Mar 23, 2020 at 01:28:33PM +1100, Martin Panter wrote:
> 
> Aha! so that's where this funny error message comes from on Debian.
> Can you remove the \n garbage at the end of it? The "echo" command
> adds its own newline at the end of the message anyway.
> 
> $ quilt series -v
> No series file found\n

Ok, I'm stupid. What a shame. Here is a fixed version, using printf
instead of echo. Many thanks for the review.

Bye, Mt.


Description: verbose error message when the series file does not exist
 patchfns.in(cat_series): Displays an error message when the $SERIES
 file does not exist, and when run in verbose mode.
Bug-Debian: https://bugs.debian.org/369908
Upstream-status: submitted 
https://lists.nongnu.org/archive/html/quilt-dev/2020-03/msg0.html

---
 quilt/scripts/patchfns.in |3 +++
 1 file changed, 3 insertions(+)

Index: b/quilt/scripts/patchfns.in
===
--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -358,6 +358,9 @@ cat_series()
sed -e '/^#/d' -e 's/^[ '$'\t'']*//' \
-e 's/[ '$'\t''].*//' -e '/^$/d' "$SERIES"
else
+   if [ "$opt_verbose" ]; then
+   printf $"No series file found\n" >&2
+   fi
return 1
fi
 }


signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch] verbose error message when the serie file does not exist

2020-03-22 Thread Martin Quinson
Hello there,

the amount of patches we have in the Debian package tend to increase
with the years, and I'd like to have your feedback on them, and
hopefully get them integrated to reduce the maintainance burden.

I'll try to get all our patches discussed here one after the other, if
you don't mind.

Here is a first very simple patch that I hope will be rather
consensual. It simply displays an error message when the serie file
does not exist (provided that the verbose option is activated).  This
was requested back in 2006 by a user who wanted his own PEBKAC to be
explicitely reported. 

Would it be acceptable for inclusion?

Thanks in advance,
Mt.



Description: verbose error message when the series file does not exist
 patchfns.in(cat_series): Displays an error message when the $SERIES
 file does not exist, and when run in verbose mode.
Bug-Debian: https://bugs.debian.org/369908

---
 quilt/scripts/patchfns.in |3 +++
 1 file changed, 3 insertions(+)

--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -358,6 +358,9 @@
sed -e '/^#/d' -e 's/^[ '$'\t'']*//' \
-e 's/[ '$'\t''].*//' -e '/^$/d' "$SERIES"
else
+   if [ "$opt_verbose" ]; then
+   echo $"No series file found\n" >&2
+   fi
return 1
fi
 }



signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] Mention guards in quilt manual page

2018-03-30 Thread Martin Quinson
Hello,

On Thu, Mar 29, 2018 at 02:26:38PM +0200, Jean Delvare wrote:
> Most people don't know about the guards helper which can be used
> to generate series files. Mentioning it in the quilt manual page
> should help raise the awareness.

making guards more visible is definitely a good idea. Maybe we should
do so in the pdf documentation too?

Thanks, Mt.

signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Race in test suite (faildiff.test)

2018-01-25 Thread Martin Quinson
Hello, 

sorry for the noise of self-answer, and for the top-posting.

I've spent some times to read 'run' in more details, and this code is
really more complex that it ought to be. In exec_test(), we are:
- opening 2 pipes
- saving away both STDIN and STDOUT to temporary file handlers
- replacing STDIN and STDOUT with some ends of the pipes
Then, if we are the parent process, we realize we should not have
changed STDIN and STDOUT so we are restoring them to their saved
value. It would be much clearer to only change STDIN and STDERR in the
child process and not mess with it in the other case.

We should also try harder to close all the file descriptors that we
are opening. I've been teaching pipes and forks for over 10 years now
(although in C, not in perl) and my experience is that bad things will
bite thy if you let some open pipes flying around. This of course
would be easier if we would not have to dupplicate STDIN and STDERR to
restore them when we notice we should not have changed them in the
first place.

I am wondering whether the bug lays in that line that I already
pointed out: open STDERR, ">&STDOUT"
I think it should read as follows, even if I never really understood
the typeglob thing in Perl. At least for sake of consistency it
should read: open *STDERR, ">&STDOUT"
Well, no. If that were the problem, STDERR would not be captured at
all when not adding 2>&1 to the shell. So I guess we should add * for
sake of consistency only. I hope it's not breaking anything either. 

My last idea would be to move the STDOUT->autoflush() to after the
redirection of STDERR (and also pass the optional 1 to autoflush()
just to make clear what we are trying to achieve). This should have no
effect at the system level, but there is maybe some oddies in Perl.

I know I should do the testing myself, but run is probably the most
intimidating part of quilt, which already undermine my hacking
self-confidence these days... Jean, would you mind sharing how you're
testing whether a given change has a positive impact on that race
condition? 

Thanks, Mt.

On Fri, Jan 26, 2018 at 04:22:09AM +0100, Martin Quinson wrote:
> Hello,
> 
> On Thu, Jan 25, 2018 at 11:11:18PM +0100, Jean Delvare wrote:
> > > Try appending a "2>&1" to direct all output to a single file.
> > 
> > Something like:
> > 
> > --- a/test/faildiff.test
> > +++ b/test/faildiff.test
> > @@ -27,7 +27,7 @@ What happens on binary files?
> > > File test.bin added to patch %{P}test.diff
> >  
> > $ printf "\\003\\000\\001" > test.bin
> > -   $ quilt diff -pab --no-index
> > +   $ quilt diff -pab --no-index 2>&1
> > >~ (Files|Binary files) a/test\.bin and b/test\.bin differ
> > > Diff failed on file 'test.bin', aborting
> > $ echo %{?}
> > 
> > I tried that already, but it doesn't help. Which doesn't really
> > surprise me: while the code in test/run is a bit beyond my own perl-fu,
> > I seem to understand that the script itself is treating stdin and stdout
> > all the same, so it would make no difference if we merge them in the
> > test case itself.
> > 
> > That, on the other hand, works around the problem:
> > 
> > --- a/test/faildiff.test
> > +++ b/test/faildiff.test
> > @@ -27,8 +27,9 @@ What happens on binary files?
> > > File test.bin added to patch %{P}test.diff
> >  
> > $ printf "\\003\\000\\001" > test.bin
> > -   $ quilt diff -pab --no-index
> > +   $ quilt diff -pab --no-index 2>/dev/null
> > >~ (Files|Binary files) a/test\.bin and b/test\.bin differ
> > +   $ quilt diff -pab --no-index 1>/dev/null
> > > Diff failed on file 'test.bin', aborting
> > $ echo %{?}
> > > 1
> > 
> > But isn't it more of a hack than an actual fix? Aren't stdout and
> > stderr supposed to be line-buffered? And when pointing to the same file
> > or tty, shouldn't the messages reach said file or tty in the same order
> > as printed in the code?
> 
> Well, I would say that stdout is line-buffered as long as it's sent to
> a tty, but if it gets onto a pipe it's not line-buffered anymore. But
> I still don't get why 2>&1 does not helps here. I cannot fully
> understand the details of the perl code either, but it seems to me
> like there is too much pipes going on in the exec_test() function. 
> 
> For example, why are we duplicating STDERR in the client code since
> we're never using the copy? Also, with the following line getting
> executed by the child process right after duplicating STDERR, I don't
> see how 

Re: [Quilt-dev] Race in test suite (faildiff.test)

2018-01-25 Thread Martin Quinson
Hello,

On Thu, Jan 25, 2018 at 11:11:18PM +0100, Jean Delvare wrote:
> > Try appending a "2>&1" to direct all output to a single file.
> 
> Something like:
> 
> --- a/test/faildiff.test
> +++ b/test/faildiff.test
> @@ -27,7 +27,7 @@ What happens on binary files?
>   > File test.bin added to patch %{P}test.diff
>  
>   $ printf "\\003\\000\\001" > test.bin
> - $ quilt diff -pab --no-index
> + $ quilt diff -pab --no-index 2>&1
>   >~ (Files|Binary files) a/test\.bin and b/test\.bin differ
>   > Diff failed on file 'test.bin', aborting
>   $ echo %{?}
> 
> I tried that already, but it doesn't help. Which doesn't really
> surprise me: while the code in test/run is a bit beyond my own perl-fu,
> I seem to understand that the script itself is treating stdin and stdout
> all the same, so it would make no difference if we merge them in the
> test case itself.
> 
> That, on the other hand, works around the problem:
> 
> --- a/test/faildiff.test
> +++ b/test/faildiff.test
> @@ -27,8 +27,9 @@ What happens on binary files?
>   > File test.bin added to patch %{P}test.diff
>  
>   $ printf "\\003\\000\\001" > test.bin
> - $ quilt diff -pab --no-index
> + $ quilt diff -pab --no-index 2>/dev/null
>   >~ (Files|Binary files) a/test\.bin and b/test\.bin differ
> + $ quilt diff -pab --no-index 1>/dev/null
>   > Diff failed on file 'test.bin', aborting
>   $ echo %{?}
>   > 1
> 
> But isn't it more of a hack than an actual fix? Aren't stdout and
> stderr supposed to be line-buffered? And when pointing to the same file
> or tty, shouldn't the messages reach said file or tty in the same order
> as printed in the code?

Well, I would say that stdout is line-buffered as long as it's sent to
a tty, but if it gets onto a pipe it's not line-buffered anymore. But
I still don't get why 2>&1 does not helps here. I cannot fully
understand the details of the perl code either, but it seems to me
like there is too much pipes going on in the exec_test() function. 

For example, why are we duplicating STDERR in the client code since
we're never using the copy? Also, with the following line getting
executed by the child process right after duplicating STDERR, I don't
see how pipe redirection at the shell level could have any impact. 

open STDERR, ">&STDOUT"

But from your tests it does. This is puzzling.

Bye, Mt.

-- 
Let's call it an accidental feature.  -- Larry Wall


signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] patch-wrapper

2016-11-17 Thread Martin Quinson
Hello,

I never used it myself and I'm not aware of anyone using it, sorry.

Bye, Mt.

- Mail original -
> Hi all,
> 
> I would like to know who is building quilt with --with-patch-wrapper and
> what you use patch-wrapper for.
> 
> As far as I can see, patch-wrapper overlaps with "quilt setup" and I
> would like to avoid maintaining 2 scripts doing the same thing. But as I
> don't use patch-wrapper myself I may be missing some use cases.
> 
> Thanks,
> --
> Jean Delvare
> SUSE L3 Support
> 
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev
> 

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Quilt 0.65 coming soon

2016-11-07 Thread Martin Quinson
On Mon, Nov 07, 2016 at 12:00:20PM +0100, Holger Wansing wrote:
> Hi,
> 
> Jean Delvare  wrote:
> > Hi Holger,
> > 
> > On Fri, 4 Nov 2016 19:54:54 +0100, Holger Wansing wrote:
> > > Jean Delvare  wrote:
> > > > Holger, Sergey, do you think you will be able to provide a final
> > > > translation update for version 0.65 soon?
> > > 
> > > Where to find the new po files?
> > > The de.po in git repo is still 100% translated.
> > 
> > Assuming you have gettext installed:
> > 
> > $ git pull
> > $ ./configure
> > $ make
> > 
> > Of course I can push untranslated files to the git repository, and push
> > again when you provide the translation, but this doubles the commit
> > history of the translation files, so I thought we could avoid it. But
> > if it makes your work harder, I'll push the untranslated files now,
> > sorry for the inconvenience.
> 
> I'm also sorry for this.
> 
> Since I am only a translator, but not a developer, I didn't know how to
> update the po here locally.
> 
> "make updatepo" is common to me, but did not work with quilt.
> 
> I looked for a README.translators or something like that, to guide me how
> to update po file. But I didn't find anything like that.

Another solution could be to use zanata.org to make the material 
available to the translators. I use it in another project and kinda
like it.

Bye, Mt.

-- 
Learning and doing is the true spirit of free software; learning without
doing gets you academic sterility, and doing without learning is all too
often the way things are done in proprietary software.   -- Raph Levien 


signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Quilt 0.65 coming soon

2016-10-22 Thread Martin Quinson
Hello,

that's a very good news, thanks for taking care of this. 

I realize that I did not package 0.64 for Debian yet. Pity. I'll try
to package 0.65 once released to avoid to forget again.

Thanks again for your work,
Mt.

On Fri, Oct 21, 2016 at 05:29:51PM +0200, Jean Delvare wrote:
> Hi all,
> 
> It's been 20 months since quilt 0.64 was released, and there has been
> quite a few fixes and improvements since then (59 commits) so I think
> I'll release a new version by the end of the month.
> 
> I have updated the French translation. It would be nice if all other
> translations could be updated too. It shouldn't take long, there's only
> one new error message and the help text of one command which was
> updated with 2 new options.
> 
> Thanks,
> -- 
> Jean Delvare
> SUSE L3 Support
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
Hi! I'm a .signature virus! Copy me into your ~/.signature, please!


signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] faildiff.test: Fix for diffutils 3.4 and later

2016-09-13 Thread Martin Quinson
Hello Jean,

indeed, my worries were unfounded. Thanks for checking it.

Bye, Mt.

On Tue, Sep 13, 2016 at 11:21:35AM +0200, Jean Delvare wrote:
> Hi Martin,
> 
> On Fri, 9 Sep 2016 17:47:33 +0200, Martin Quinson wrote:
> > this seems sensible to refuse binary patches as we cannot use them.
> > But I'm afraid that the detection method will not play well with
> > translations. I don't have no better idea, unfortunately.
> 
> It doesn't seem to be a problem. I have a French locale (fr_FR.UTF-8)
> and quilt is talking to me in French, but the output of diff is still
> in English.
> 
> At the beginning of patchfns, we do:
> 
> ORIGINAL_LANG=$LANG
> export LANG=POSIX
> 
> As I understand it, it means we can assume English output from
> everything we call, except in the few cases where we explicitly restore
> the original locale before the call.
> 
> -- 
> Jean Delvare
> SUSE L3 Support
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
Nous avons neuf mois de vie privée avant de naître, ça devrait nous
suffire. -- Heathcote Williams, Actuel n°48, novembre 74.


signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] faildiff.test: Fix for diffutils 3.4 and later

2016-09-09 Thread Martin Quinson
Hello,

this seems sensible to refuse binary patches as we cannot use them.
But I'm afraid that the detection method will not play well with
translations. I don't have no better idea, unfortunately.

Bye, Mt.

On Fri, Sep 09, 2016 at 04:14:53PM +0200, Jean Delvare wrote:
> Hi Andreas,
> 
> On Fri, 9 Sep 2016 11:09:08 +0200, Andreas Grünbacher wrote:
> > 2016-09-09 10:56 GMT+02:00 Jean Delvare :
> > >
> > > Since diffutils version 3.4, diff no longer returns an error code for
> > > binary files. Remove this test from faildiff.test.
> > 
> > Okay, thanks.
> 
> Actually the following would be a better fix for the same problem:
> ---
>  quilt/scripts/patchfns.in |8 +++-
>  1 file changed, 7 insertions(+), 1 deletion(-)
> 
> --- quilt.orig/quilt/scripts/patchfns.in  2016-01-24 11:38:24.047466508 
> +0100
> +++ quilt/quilt/scripts/patchfns.in   2016-09-09 12:53:40.110084270 +0200
> @@ -741,6 +741,12 @@ diff_file()
>"$old_file" "$new_file" \
>   | if read line
>   then
> + if [[ "$line" =~ ^Binary\ files\ .*\ differ$ ]]
> + then
> + echo "$line"
> + return 1
> + fi
> +
>   if [ -z "$QUILT_NO_DIFF_INDEX" ]
>   then
>   echo "Index: $index"
> @@ -751,7 +757,7 @@ diff_file()
>   fi
>  
>   # Test the return value of diff, and propagate the error retcode if any
> - if [ ${PIPESTATUS[0]} == 2 ]
> + if [ ${PIPESTATUS[0]} == 2 -o ${PIPESTATUS[1]} == 1 ]
>   then
>   return 1
>   fi
> 
> Comments welcome. The problem is that fixing the test case is not
> enough. As "diff" no longer fails on binary files, "quilt refresh" will
> include the output of diff for binary files, and that output looks bad:
> 
> Binary files w.orig/test.bin2016-09-09 10:19:10.621752409 +0200 and 
> w/test.bin  2016-09-09 10:19:24.349917252 +0200 differ
> 
> Also "quilt refresh" doesn't replace these lines, it adds them... So
> they stack up. Plus it doesn't make any sense in the context of quilt
> anyway, if we are not able to apply the changes, we can't consider that
> the file is actually part of the patch.
> 
> So I'd rather force the failure as was happening before.
> 
> -- 
> Jean Delvare
> SUSE L3 Support
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
97.3% of all statistics are made up. 


signature.asc
Description: PGP signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] Fwd: Re: Fwd: Quilt 0.64 coming soon

2015-02-05 Thread Martin Quinson
Hi Jean, 

could you delay the release by a few days, please? Holger (in CC)
needs that delay to polish the german translation.

Holger, could you please post your translation to the quilt mailing
list when done? I'm offline next week so I will not be able to forward
nor to commit your work.

We will indeed try to give longer delays for translations next time,
sorry -- that's a first for us.

Thanks everyone for your work,
Mt.

- Forwarded message from Holger Wansing  -

Date: Fri, 6 Feb 2015 06:07:47 +0100
From: Holger Wansing 
To: Martin Quinson 
Cc: debian-l10n-ger...@lists.debian.org, debian-i...@lists.debian.org
Subject: Re: Fwd: [Quilt-dev] Quilt 0.64 coming soon]
X-Mailer: Sylpheed 3.2.0 (GTK+ 2.24.10; i486-pc-linux-gnu)

Hi,

Martin Quinson  wrote:
> Hello dear translators,
> 
> the next upstream release of the Quilt software is planned for next
> friday, and we are currently seeking for translators (in particular in
> German as one would only have to update the files, not start from
> scratch). French and Japaneese are already worked on, thanks.

I am nearly finished updating the german file.
So please delay the upload some more days.

However 3 days are a really too short timeframe for translation
update, since there is also time required for reviewing on
debian-l10n-german. In this case I will probably sent another file
in some weeks, when reviewing is done.


Holger


-- 

Created with Sylpheed 3.2.0 under
D E B I A N   L I N U X   7 . 0   W H E E Z Y !

Registered Linux User #311290 - https://linuxcounter.net/


- End forwarded message -

-- 
There is enough for the need of everyone in this world, 
but not for the greed of everyone.
   --- Mahatma Gandhi


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Quilt 0.64 coming soon

2015-01-30 Thread Martin Quinson
Hello,



On Fri, Jan 30, 2015 at 03:26:50PM +0100, Jean Delvare wrote:
> 
> Well I reviewed this patch of yours but did not get any feedback:
> http://lists.nongnu.org/archive/html/quilt-dev/2014-06/msg00014.html
> As long as my concerns are not addressed, I won't look further into it,
> sorry.
> 

Perfectly fare, of course. I was just feeling bad for not working
further on this. That's of course no reason for delaying the release.

Sorry, Mt

-- 
Quand on étrangle un Schtroumpf, il devient de quelle couleur ?


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Quilt 0.64 coming soon

2015-01-28 Thread Martin Quinson
On Wed, Jan 28, 2015 at 12:13:14PM +0100, Jean Delvare wrote:
> Hi all,
> 
> It's been 9 months since quilt 0.63 was released, and there has been
> quite a few fixes and improvements since then (51 commits and counting)
> so I think I'll release a new version in the next few days.

That would be a wonderful news, even if I feel bad about not
finalizing my patches. 

For example, the one testing the bash completion is neat but not
functionnal. We had to disable it in debian as it was failing from
time to time. I won't have the time to improve its state in any
foreseable future, so if you feel like giving it a shoot, that'd be
great. If not, then testing the completion scripts is definitely not a
release blocker.

http://sources.debian.net/src/quilt/0.63-3/debian/patches/test-completion/
https://savannah.nongnu.org/patch/index.php?8448
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=751109

Thanks for your great work,
Mt

-- 
Si la vie privée est hors-la-loi, seuls les hors-la-loi auront une vie privée
   -- P. Zimmermann, inspiré d'une maxime de Thomas Jefferson.


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] quilt/mail: remove procmail dependency

2015-01-27 Thread Martin Quinson
Hello,

On Tue, Jan 27, 2015 at 01:05:08PM +0100, Jean Delvare wrote:
> 
> I like it too, however I am not so happy with sed being called twice. I
> think we should be able to achieve the same with a single call.
> 
> > > +  sed -n "/^${header}/,/^[^[:blank:]]/ { /^${header}/ { p; n; }; 
> > > /^[^[:blank:]]/q; /^$/q; p; }" | sed "s/^${header}//"
> 
> I think the following should work equally well?
> 
>   sed -n "/^${header}/,/^[^[:blank:]]/ { /^${header}/ { s/^${header}//p; 
> n; }; /^[^[:blank:]]/q; /^$/q; p; }"

Wow. Even better.

Bye, Mt.

-- 
On the Internet nobody can hear you being subtle.   -- Linus Torvalds


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] quilt/mail: remove procmail dependency

2015-01-26 Thread Martin Quinson
Hello,

I've read the patch, and it seems ok to me. Many thanks for that.

Bye, Mt.

On Mon, Jan 26, 2015 at 06:01:09PM -0600, Kent R. Spillner wrote:
> quilt depends on procmail because 'quilt mail' requires formail.
> However, formail is only used to extract header values from messages.
> Since quilt already requires sed we can replace formail -x uses with
> sed instead.  The sed script is slightly complicated because it
> needs to handle the case of "Long Header Fields" definied in RFC
> 2822, but essentially all it's doing is: look for the first line
> beginning with the name of header we are looking for, and print
> every line until one that does not start with blanks.
> 
> Signed-off-by: Kent R. Spillner 
> ---
>  po/de.po  |  4 
>  po/fr.po  |  6 --
>  po/ja.po  |  4 
>  po/quilt.pot  |  4 
>  po/ru.po  |  4 
>  quilt/mail.in | 33 +
>  6 files changed, 21 insertions(+), 34 deletions(-)
> 
> diff --git a/po/de.po b/po/de.po
> index e8d32c8..923074d 100644
> --- a/po/de.po
> +++ b/po/de.po
> @@ -834,10 +834,6 @@ msgstr ""
>  msgid "Introduction message already specified"
>  msgstr "Einleitung gespeichert als %s\\n"
>  
> -#: quilt/mail.in:262
> -msgid "You have to install 'formail' to use 'quilt mail'"
> -msgstr ""
> -
>  #: quilt/mail.in:305
>  msgid "Could not determine the envelope sender address. Please use --sender."
>  msgstr ""
> diff --git a/po/fr.po b/po/fr.po
> index ca85579..72dc867 100644
> --- a/po/fr.po
> +++ b/po/fr.po
> @@ -846,12 +846,6 @@ msgstr ""
>  msgid "Introduction message already specified"
>  msgstr "Message d'introduction déjà spécifié"
>  
> -#: quilt/mail.in:262
> -msgid "You have to install 'formail' to use 'quilt mail'"
> -msgstr ""
> -"Vous devez installer le programme «formail» afin d'utiliser la commande "
> -"«quilt mail»"
> -
>  #: quilt/mail.in:305
>  msgid "Could not determine the envelope sender address. Please use --sender."
>  msgstr "Impossible de déterminer l'adresse d'expéditeur. Utilisez --sender."
> diff --git a/po/ja.po b/po/ja.po
> index 8e3dadd..f04c22d 100644
> --- a/po/ja.po
> +++ b/po/ja.po
> @@ -818,10 +818,6 @@ msgstr ""
>  msgid "Introduction message already specified"
>  msgstr "序文は %s という名前で保存されました\\n"
>  
> -#: quilt/mail.in:262
> -msgid "You have to install 'formail' to use 'quilt mail'"
> -msgstr ""
> -
>  #: quilt/mail.in:305
>  msgid "Could not determine the envelope sender address. Please use --sender."
>  msgstr ""
> diff --git a/po/quilt.pot b/po/quilt.pot
> index b1d2889..44d95c0 100644
> --- a/po/quilt.pot
> +++ b/po/quilt.pot
> @@ -544,10 +544,6 @@ msgstr ""
>  msgid "Introduction message already specified"
>  msgstr ""
>  
> -#: quilt/mail.in:262
> -msgid "You have to install 'formail' to use 'quilt mail'"
> -msgstr ""
> -
>  #: quilt/mail.in:305
>  msgid "Could not determine the envelope sender address. Please use --sender."
>  msgstr ""
> diff --git a/po/ru.po b/po/ru.po
> index 6e91e3a..fdec6f3 100644
> --- a/po/ru.po
> +++ b/po/ru.po
> @@ -762,10 +762,6 @@ msgstr ""
>  msgid "Introduction message already specified"
>  msgstr ""
>  
> -#: quilt/mail.in:262
> -msgid "You have to install 'formail' to use 'quilt mail'"
> -msgstr ""
> -
>  #: quilt/mail.in:305
>  msgid "Could not determine the envelope sender address. Please use --sender."
>  msgstr ""
> diff --git a/quilt/mail.in b/quilt/mail.in
> index 5e519f9..ba48851 100644
> --- a/quilt/mail.in
> +++ b/quilt/mail.in
> @@ -81,6 +81,18 @@ msgid()
>   echo "$timestamp@${opt_sender_address#*@}"
>  }
>  
> +# Extract RFC 2822 compliant header values, including Long Header Fields,
> +# from messages
> +
> +extract_header_value()
> +{
> +  local header=$1
> +
> +  # Long Header Fields may span multiple lines, in which case CRLF
> +  # is followed by space or tab (RFC 2822)
> +  sed -n "/^${header}/,/^[^[:blank:]]/ { /^${header}/ { p; n; }; 
> /^[^[:blank:]]/q; /^$/q; p; }" | sed "s/^${header}//"
> +}
> +
>  # See RFC 2822 Internet Message Format for how the In-Reply-To and
>  # References headers are generated...
>  
> @@ -88,7 +100,7 @@ in_reply_to_header()
>  {
>   local message=$1 message_id
>  
> - message_id=$(formail -x Message-ID: < "$message")
> + message_id=$(extract_header_value Message-ID: < "$message")
>   message_id=${message_id# }
>   [ -n "$message_id" ] && echo "In-Reply-To: $message_id"
>  }
> @@ -97,14 +109,14 @@ references_header()
>  {
>   local message=$1 message_id references in_reply_to
>  
> - message_id=$(formail -x Message-ID: < "$message")
> + message_id=$(extract_header_value Message-ID: < "$message")
>   message_id=${message_id# }
>  
> - references=$(formail -x References: < "$message")
> + references=$(extract_header_value References: < "$message")
>   references=${references# }
>   if [ -z "$references" ]
>   then
> - in_reply_to=$(formail -x In-Reply-To: < "$message")
> + in_reply_to=$(ext

Re: [Quilt-dev] Support

2014-07-22 Thread Martin Quinson
May I ask why you are using a version of quilt that was released about
ten years ago? You should try again with a version 0.63 to check if it
works better for you ;)

HTH, Mt.

On Wed, Jul 23, 2014 at 01:31:10AM +0700, Truong Tong xuan wrote:
> Hi Support,
> 
> I'm using mac os to build quilt version 0.39. All config was ok, but i got
> error message below:
> 
> quilt version 0.39 configured.
> 
> 
> Using '/usr/local' for installation prefix.
> 
> 
> Report bugs to quilt-dev@nongnu.org
> 
> Truongs-Mac-mini:quilt-0.39 truongtongxuan$ make
> 
> bin/quilt.in -> bin/quilt
> 
> chmod: illegal option -- -
> 
> usage: chmod [-fhv] [-R [-H | -L | -P]] [-a | +a | =a  [i][# [ n]]]
> mode|entry file ...
> 
> chmod [-fhv] [-R [-H | -L | -P]] [-E | -C | -N | -i | -I] file ...
> 
> make: *** [bin/quilt] Error 1
> 
> 
> Please help me resolve now.
> 
> 
> Many thanks,
> 
> David



signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 5/5] Informative message when using graph without graphviz

2014-06-09 Thread Martin Quinson
On Mon, Jun 09, 2014 at 02:38:42PM +0200, Jean Delvare wrote:
> Le Monday 09 June 2014 à 14:24 +0200, Jean Delvare a écrit :
> > Hi Martin,
> > 
> > Le Friday 09 May 2014 à 00:13 +0200, Martin Quinson a écrit :
> > > in attachment, a new version of this patch taking your remarks into
> > > account.
> > 
> > Looks good, except that you don't need to add dots at the end of error
> > messages, what you need to add is \n, otherwise the error message and
> > shell prompt get mixed.
> > 
> > I have a similar patch adding a check for rpmbuild in the "setup"
> > command. I think it may make sense to add a small helper function to
> > handle these checks in a unified way.
> 
> I fixed that and committed both patches.

Thanks for your help on that too!

Bye, Mt.

-- 
Your research agenda is so outdated that your results are on a
Wikipedia page already. -- Bastard Reviewer From Hell   


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 5/5] Informative message when using graph without graphviz

2014-05-08 Thread Martin Quinson
Hello Jean,

in attachment, a new version of this patch taking your remarks into
account.

Bye, Mt.
Description: Informative message when using graph without graphviz
 Previously, trying to use the graph subcommand without graphviz being
 installed resulted in a cryptic error message: 
 .
 Can't exec "tred": No such file or directory at /usr/lib/perl/5.14/IO/File.pm 
line 66,  line 1.
 .
 graphviz is already in the Suggests field of the debian package, and
 we cannot raise this dependency severity given the central role of
 quilt in the debian infrastructure. This informative error message is
 much more sensible.
 .
 Also, merge the error message with the one from quilt mail when
 formail is not installed to ease the life of translators.
Author: Martin Quinson 
Bug-Debian: http://bugs.debian.org/659944
Forwarded: 2014-01-18

---
 quilt/graph.in |   12 
 quilt/mail.in  |2 +-
 2 files changed, 13 insertions(+), 1 deletion(-)

Index: b/quilt/graph.in
===
--- a/quilt/graph.in
+++ b/quilt/graph.in
@@ -109,6 +109,18 @@
usage
 fi
 
+if [ "$opt_format" = "ps" ] && ! type dot &> /dev/null
+then
+   printf $"You have to install '%s' (from package %s) to use 'quilt %s'." 
dot graphviz "graph -T"
+   exit 1
+fi
+
+if [ -n "$opt_reduce" ] && ! type tred &> /dev/null
+then
+   printf $"You have to install '%s' (from package %s) to use 'quilt %s'." 
tred graphviz "graph --reduce"
+   exit 1
+fi
+
 if [ -z "$opt_all" ]
 then
patch=$(find_applied_patch "$1") || exit 1
Index: b/quilt/mail.in
===
--- a/quilt/mail.in
+++ b/quilt/mail.in
@@ -259,7 +259,7 @@
 # check if formail is installed before doing anything
 if ! type formail &> /dev/null
 then
-   echo $"You have to install 'formail' to use 'quilt mail'" >&2
+   printf $"You have to install '%s' (from package %s) to use 'quilt %s'." 
formail procmail mail >&2
exit 1
 fi
 


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Quilt configuration associated with a source code tree/patch series

2014-05-08 Thread Martin Quinson
Hello there,

On Mon, May 05, 2014 at 11:03:28AM +0200, Jean Delvare wrote:
> Hi Martin, Frank,
> 
> Le Monday 05 May 2014 à 00:04 +0200, Martin Quinson a écrit :

> > It would be interesting to add the feature that you are speaking of.
> > The change could be as simple as the following (untested):
> > 
> > diff --git a/quilt/scripts/patchfns.in b/quilt/scripts/patchfns.in
> > index 5feee9f..d2113ec 100644
> > --- a/quilt/scripts/patchfns.in
> > +++ b/quilt/scripts/patchfns.in
> > @@ -1089,6 +1089,12 @@ fi
> >  
> >  DB="$QUILT_PC/applied-patches"
> >  
> > +# Source the repository-specific configuration
> > +if [ -e "$QUILT_PATCHES/quiltrc" ]
> > +then
> > +   source "$QUILT_PATCHES/quiltrc"
> 
> This raises a name space question. Although unlikely, "quiltrc" is a

The patch I just sent to check that the patch name does not contain
spaces and is not "series" makes it easy to deal with that namespace
conflict (that was part of the purpose).

> Also I think you want to move the code up in the patchfns file, right
> after the user's (or system) quiltrc file is read. Otherwise adding the
> default arguments for the current command will be done based on the
> wrong settings, which will defeat the point of project-specific
> settings.
> 
> > +fi
> > +
> >  if [ -z "$skip_version_check" ] && ! version_check
> >  then
> > printf $"The working tree was created by an older version of quilt. 
> > Please run 'quilt upgrade'.\n" >&2
> > -->8--
> > 
> > Note that this would override the user and global settings instead of
> > the contrary. Note also that for now, if both /etc/quilt.quiltrc and
> > ~/.quiltrc exist, only the ~/.quiltrc is used while the /etc one is
> > completely ignored (see at the beginning of bin/quilt.in)
> > 
> > If you guys like the idea of having a configuration file per
> > source tree, I'll cleanup my patch, document this new feature and
> > everything. 
> 
> I've been thinking about it too, but couldn't make up my mind one way or
> another. Thanks to both of you for bringing the topic up again, let's
> sort it out now.
> 
> If we try to add support for project-specific configuration files, we
> need to decide if the project-specific configuration file completely
> takes over the user or system configuration file (the same way the user
> settings currently do over system settings), or if the project-specific
> settings should be merged together with the user settings (we've never
> done that before.)
> 
> If the first case, it might be inconvenient as some settings really
> qualify as user preference and are not tied to a specific project. This
> is the case of EDITOR, QUILT_PAGER and QUILT_PATCHES_PREFIX for example.
> If we only read the project configuration file, the user will suddenly
> miss these settings. That would be very confusing. Unfortunately there
> is no automatic way to identify which settings are user-specific.
> 
> In the second case, we have to decide which configuration file will be
> the base and which configuration file will be the overlay. Letting all
> user settings take over project settings would pretty much void the
> point of having a project-specific configuration file in the first
> place, so obviously it would have to be the other way around. Which is
> what Martin proposed if I read the code correctly, so apparently we
> agree on that, which is good :)
> 
> Note that it then becomes each project's responsibility to come up with
> a sane quilt configuration file, and not overwrite settings which only
> affect the user and not the project. For example, it would be perfectly
> legitimate for a project to set QUILT_REFRESH_ARGS, but QUILT_DIFF_ARGS
> should be left to the user to decide.

I'm not sure that each solution makes a big difference. It's perfectly
possible to set some variables only if they are not set yet with
${param:-val} and such.

So, it's maybe better to let the user settings override everything at
the end. The only difficulty is that QUILT_PATCHES where the
configuration file will live can be changed by the user configuration,
somehow. That is why I decided to do it the way I did.

Not sure, yet.
Mt.

-- 
Each language has its purpose, however humble.  
Each language expresses the Yin and Yang of Software.
Each language has its place within the Tao.
But do not program in PHP if you can avoid it.
-- The Tao of Programming


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch] Enforcing valid patch names

2014-05-08 Thread Martin Quinson
In attachement.
Description: Enforce valid patch names
 Allowing patch names to contain spaces would require major changes
 (such as the format of the series file), so we'd better detect that
 the user tries to use spaces in the patch name, and refuse it.
 .
 Also, refuse patches named series, as it would result in awful
 corruptions of the internal state.
Author: Martin Quinson
---
 quilt/fork.in  |2 +
 quilt/import.in|2 +
 quilt/new.in   |2 +
 quilt/rename.in|2 +
 quilt/scripts/patchfns.in  |   17 
 test/restrict-patch-names.test |   56 +
 6 files changed, 81 insertions(+)

Index: b/quilt/scripts/patchfns.in
===
--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -951,6 +951,23 @@
return 1
 }
 
+# We don't want patch with spaces in their name
+check_potential_patchname()
+{
+   local patch="$1"
+   if echo "$patch" | grep -q ' '
+   then
+   printf $"Patch name '%s' invalid: cannot contain spaces.\n" 
"$patch" >&2
+   exit 1
+   fi
+
+   if [ "$patch" = "$QUILT_SERIES" ]
+   then
+   printf $"No patch can be named '%s' as this would conflict with 
the\nseries file used internally by quilt.\n" "$QUILT_SERIES" >&2
+   exit 1
+   fi
+}
+
 print_patch()
 {
echo "${QUILT_PATCHES_PREFIX:+$SUBDIR_DOWN$QUILT_PATCHES/}$1"
Index: b/quilt/new.in
===
--- a/quilt/new.in
+++ b/quilt/new.in
@@ -92,6 +92,8 @@
 
 patch=${1#$QUILT_PATCHES/}
 
+check_potential_patchname "$patch"
+
 if patch_in_series $patch
 then
printf $"Patch %s exists already\n" "$(print_patch $patch)" >&2
Index: b/quilt/import.in
===
--- a/quilt/import.in
+++ b/quilt/import.in
@@ -186,6 +186,8 @@
patch=${orig_patch_file##*/}
fi
 
+   check_potential_patchname "$patch"
+
patch_file=$(find_patch_file "$orig_patch_file") || exit 1
merged_patch_file="$patch_file"
 
Index: b/quilt/fork.in
===
--- a/quilt/fork.in
+++ b/quilt/fork.in
@@ -77,6 +77,8 @@
 
 new_patch=${new_patch#$QUILT_PATCHES/}
 
+check_potential_patchname "$new_patch"
+
 if patch_in_series $new_patch || \
[ -d "$QUILT_PC/$new_patch" ] || \
[ -e "$(patch_file_name $new_patch)" ]
Index: b/quilt/rename.in
===
--- a/quilt/rename.in
+++ b/quilt/rename.in
@@ -77,6 +77,8 @@
 
 new_patch=${1#$QUILT_PATCHES/}
 
+check_potential_patchname "$new_patch"
+
 if patch_in_series "$new_patch" || \
[ -d "$QUILT_PC/$new_patch" ] || \
[ -e "$(patch_file_name "$new_patch")" ]
Index: b/test/restrict-patch-names.test
===
--- /dev/null
+++ b/test/restrict-patch-names.test
@@ -0,0 +1,56 @@
+$ mkdir patches
+
+$ quilt new "name with spaces"
+> Patch name 'name with spaces' invalid: cannot contain spaces.
+$ echo %{?}
+> 1
+
+$ quilt new series
+> No patch can be named 'series' as this would conflict with the
+> series file used internally by quilt.
+$ echo %{?}
+> 1
+
+
+
+$ echo "+toto" > patchfile
+
+$ quilt import -P 'name2 with spaces' patchfile
+> Patch name 'name2 with spaces' invalid: cannot contain spaces.
+$ echo %{?}
+> 1
+
+$ quilt import -P series patchfile
+> No patch can be named 'series' as this would conflict with the
+> series file used internally by quilt.
+$ echo %{?}
+> 1
+
+
+
+$ quilt new patch1
+> Patch patches/patch1 is now on top
+
+$ quilt fork "patch 1"
+> Patch name 'patch 1' invalid: cannot contain spaces.
+$ echo %{?}
+> 1
+
+$ quilt fork series
+> No patch can be named 'series' as this would conflict with the
+> series file used internally by quilt.
+$ echo %{?}
+> 1
+
+
+
+$ quilt rename "patch 1"
+> Patch name 'patch 1' invalid: cannot contain spaces.
+$ echo %{?}
+> 1
+
+$ quilt rename series
+> No patch can be named 'series' as this would conflict with the
+> series file used internally by quilt.
+$ echo %{?}
+> 1


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] quilt 0.63 just released

2014-05-07 Thread Martin Quinson
Hello, 

I'm sorry, I got the release process wrong, and some files laying on
my hard disk unfortunately landed within the released tarball.

So, I just released 0.63 that superseeds and replace the buggy 0.62
release.

Sorry, Mt.

On Wed, May 07, 2014 at 08:22:04PM +0200, Martin Quinson wrote:
> Hello,
> 
> I just released the version 0.62 of quilt. After just 5 months of
> development, I think that this was a productive time:
> 
> Version 0.62 (Wed May 07 2014)
>   - New NEWS file, containing a human-readable changelog
>   - Option -E is no longer passed to patch by default
>   - Huge performance improvement (e.g., for commands series, applied and 
> unapplied)
>   - configure: Add compat symlinks for cp and md5sum
>   - Return 2 when there is nothing to do, contrasting with errors (ret=1)
>   - Exit with an error when diff's retcode=2 (error) on patch refresh
>   - bash_completion: cleanups and performance improvement (Savannah's #27111)
>   - test/run: Use perl module Text::ParseWords (+ performance improvement)
>   - Add some tests to our testsuite, for a better coverage
>   - Fix heuristic for unapplied patches with timestamps
>   - Bug fix: Patches emptying files should work now
>   - Bug fix: Check for duplicate patch in series (Savannah's #20628)
>   - Portability fixes for older Bash and GNU patch
> 
> 
> Let's start the next development cycle! Personnaly, I have some more
> patches from Debian to update, cleanup and propose for adoption. What
> do YOU plan to do for quilt in the next few weeks?
> 
> Enjoy, Mt.





signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] quilt 0.62 just released

2014-05-07 Thread Martin Quinson
Hello,

I just released the version 0.62 of quilt. After just 5 months of
development, I think that this was a productive time:

Version 0.62 (Wed May 07 2014)
  - New NEWS file, containing a human-readable changelog
  - Option -E is no longer passed to patch by default
  - Huge performance improvement (e.g., for commands series, applied and 
unapplied)
  - configure: Add compat symlinks for cp and md5sum
  - Return 2 when there is nothing to do, contrasting with errors (ret=1)
  - Exit with an error when diff's retcode=2 (error) on patch refresh
  - bash_completion: cleanups and performance improvement (Savannah's #27111)
  - test/run: Use perl module Text::ParseWords (+ performance improvement)
  - Add some tests to our testsuite, for a better coverage
  - Fix heuristic for unapplied patches with timestamps
  - Bug fix: Patches emptying files should work now
  - Bug fix: Check for duplicate patch in series (Savannah's #20628)
  - Portability fixes for older Bash and GNU patch


Let's start the next development cycle! Personnaly, I have some more
patches from Debian to update, cleanup and propose for adoption. What
do YOU plan to do for quilt in the next few weeks?

Enjoy, Mt.

signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] Releasing 0.62?

2014-05-05 Thread Martin Quinson
Hello people, 

I think that we are in a very good state to release the next version
of quilt. I'll do so very soon (before the end of the week) unless
someone objects. 

I just commited a tentative documentation of that version in the NEWS
files. Please review that change, correct and augment that as needed.

Thanks for your time,
Mt.

-- 
It is impossible to travel faster than light, and certainly not desirable,
as one's hat keeps blowing off. -- Woody Allen.


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Quilt configuration associated with a source code tree/patch series

2014-05-05 Thread Martin Quinson
Hello Frank,

Sorry for the delay of this answer. I wanted to see whether someone
could come up with a positive answer, and then I forgot it, sorry.



On Mon, Mar 31, 2014 at 10:27:35AM -0400, Frank Bormann wrote:
> Hi Everyone,
> 
> I am new to quilt and just finished to read through the documentation.
> 
> I was wondering if quilt has any concept of accepting quiltrc configuration
> linked to a particular project/source code tree/patch series.
> 
> I know that there is ~/.quiltrc which binds to a particular individual and
> /etc/quilt.quiltrc that binds to a particular system. I was wondering if
> there is a similar concept where configuration binds to a project/source
> tree/patch series, that I may be missing. Ideally in such way that any
> project configuration may be overridden by the system-wide and individual
> user config files.
> 
> The idea is to track changes to a patch series in a version control system
> and implement branches by having QUILT_SERIES set to different series files
> for each individual branch.

As far as I know, the ability to configure quilt for a given
repository is actually *very* limited. Only the patch directory and
the series file (respectively equivalent to QUILT_PATCHES and
QUILT_SERIES) are saved in the .pc/ directory (in .pc/.quilt_patches
and .pc/.quilt_series).

Actually, I'm not sure I'd advise you to mess with these files
manually. I never temper with the content of .pc myself.


It would be interesting to add the feature that you are speaking of.
The change could be as simple as the following (untested):

diff --git a/quilt/scripts/patchfns.in b/quilt/scripts/patchfns.in
index 5feee9f..d2113ec 100644
--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -1089,6 +1089,12 @@ fi
 
 DB="$QUILT_PC/applied-patches"
 
+# Source the repository-specific configuration
+if [ -e "$QUILT_PATCHES/quiltrc" ]
+then
+   source "$QUILT_PATCHES/quiltrc"
+fi
+
 if [ -z "$skip_version_check" ] && ! version_check
 then
printf $"The working tree was created by an older version of quilt. 
Please run 'quilt upgrade'.\n" >&2
-->8--

Note that this would override the user and global settings instead of
the contrary. Note also that for now, if both /etc/quilt.quiltrc and
~/.quiltrc exist, only the ~/.quiltrc is used while the /etc one is
completely ignored (see at the beginning of bin/quilt.in)

If you guys like the idea of having a configuration file per
source tree, I'll cleanup my patch, document this new feature and
everything. 

Bye, Mt.

-- 
It is easier to port a shell than a shell script. -- Larry Wall


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] Add a NEWS file

2014-03-12 Thread Martin Quinson
Thanks for that, that's increadibly informative, even for me that
should have followed the development of quilt since then ;)

Bye, Mt.

On Wed, Mar 12, 2014 at 03:05:37PM +0100, Jean Delvare wrote:
> Add a NEWS file containing a summary of the most important
> user-visible changes in each version of quilt. The goal is to
> replace quilt.changes, which was partly incomplete and partly
> redundant with the git log, by something useful for packagers and
> users.
> ---
> As discussed earlier on the quilt-dev list:
> http://lists.nongnu.org/archive/html/quilt-dev/2014-02/msg00034.html
> 
> Comments and suggestions on both the contents and the format are
> welcome.
> 
> I only went back to version 0.50. If anyone has good change summaries
> for older versions, please contribute.
> 
>  NEWS |   43 +++
>  1 file changed, 43 insertions(+)
> 
> --- /dev/null
> +++ b/NEWS
> @@ -0,0 +1,43 @@
> +Version 0.61 (2013-12-08)
> +  - No new feature, but almost two years of fixes and minor improvements
> +  - Fix support for ./configure --with-xargs
> +  - Parameter quoting fixes to many commands
> +  - Various fixes to the pop, push, refresh and patches commands
> +  - Translation fixes
> +  - setup: Many fixes and improvements
> +  - remove-trailing-ws: Several fixes and improvements
> +  - remove-trailing-ws: Add a dedicated test case
> +  - quilt.el: Many fixes and improvements (emacs integration)
> +
> +Version 0.60 (2012-02-29)
> +  - BSD compatibility improvements
> +  - grep: Support file names which include spaces
> +  - import: Fix import of relative patches
> +  - mail: Several fixes
> +  - setup: Support directory and archive names which include spaces
> +  - backup-files: rewritten from C to bash
> +  - backup-files: Add a dedicated test case
> +
> +Version 0.51 (2012-01-28)
> +  - Fix support for ./configure --docdir
> +  - Various $TMPDIR fixes
> +  - mail: Fix delivery address checking
> +  - mail: CC people in more common patch headers
> +  - push: Fix bash completion
> +  - inspect: Complain if wrapper script can't be executed
> +
> +Version 0.50 (2011-12-05)
> +  - 34 months of fixes and improvements, too many to list them all
> +  - Fix detection of the patch version
> +  - Avoid error messages when building due to missing git-desc file
> +  - Add support for lzma and xz compression formats
> +  - import: Fix confusing French translation
> +  - mail: Stop using =~ for older versions of bash
> +  - mail: Fix a temporary directory leak
> +  - revert: Stop using cp -l for filesystems not supporting hard links
> +  - revert: Add bash completion support
> +  - setup: Add --fuzz parameter
> +  - setup: Add support for reverse patches
> +  - inspect: Fix shell syntax errors
> +  - Fix error in test case create-delete
> +
> 
> 
> -- 
> Jean Delvare
> SUSE L3 Support
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
This paper needs a major rewrite to fix the English, make it more
concise, explain clearly what exactly is the performance evaluation
methodology, and how it is different from the obvious. 
 -- Bastard Reviewer From Hell (seen for real as PC member)


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch] Make it possible to test the bash completion script

2014-02-26 Thread martin . quinson
- Add a helper script that runs a completion and checks that it
  reaches the expected outcome
- Add an example of test (in our usual test suite) using it
- Caveat: you probably need to chmod +x test/run-test-completion.in

This closes #41688.

---
 Makefile.in |6 +-
 test/completion.test|   10 ++
 test/run-test-completion.in |   42 ++
 3 files changed, 57 insertions(+), 1 deletion(-)

Index: b/test/completion.test
===
--- /dev/null
+++ b/test/completion.test
@@ -0,0 +1,10 @@
+$ ../run-test-completion add quilt ad
+>~ PASS:.*
+
+$ ../run-test-completion "add annotate applied" quilt a
+>~ PASS:.*
+
+$ ../run-test-completion "" quilt toppp
+>~ PASS:.*
+
+
Index: b/test/run-test-completion.in
===
--- /dev/null
+++ b/test/run-test-completion.in
@@ -0,0 +1,42 @@
+#! @BASH@
+
+# Little test runner for the bash completion
+
+# Usage:   run-test-completion "expected output" the command line to complete
+#
+# $ run-test-completion "add" quilt ad
+# PASS: quilt ad -> add
+# $ run-test-completion "add" quilt a
+# FAIL: quilt a -> add annotate applied  !=  add
+# $ run-test-completion "" quilt toppp
+# PASS: quilt toppp -> 
+
+
+#  This script is free software; you can redistribute it and/or modify
+#  it under the terms of the GNU General Public License version 2 as
+#  published by the Free Software Foundation.
+#
+#  See the COPYING and AUTHORS files for more details.
+
+
+set -e
+source ../../bash_completion
+
+expected_output=$1
+shift
+
+declare -a COMP_WORDS=()
+for arg in "$@" ; do
+  COMP_WORDS[${#COMP_WORDS[@]}]=$arg
+done
+COMP_CWORD=${#COMP_WORDS[@]}-1
+
+set +e # _quilt_completion fails when completing something with no existing 
completion, such as "quilt to"
+_quilt_completion -o filenames quilt
+observed_output="${COMPREPLY[*]}"
+
+if [ "$expected_output" = "$observed_output" ] ; then
+  echo "PASS: $@ -> $expected_output"
+else
+  echo "FAIL: $@ -> $observed_output  !=  $expected_output"
+fi
Index: b/Makefile.in
===
--- a/Makefile.in
+++ b/Makefile.in
@@ -79,6 +79,9 @@
 SRC += $(QUILT_SRC:%=quilt/%)
 DIRT +=$(QUILT_IN:%=quilt/%)
 
+SRC += test/run-test-completion.in
+DIRT +=test/run-test-completion
+
 SCRIPTS_IN :=  patchfns inspect dependency-graph edmail\
remove-trailing-ws backup-files
 
@@ -148,7 +151,8 @@
 
 scripts : $(BIN:%=bin/%) $(QUILT:%=quilt/%)\
  $(SCRIPTS:%=quilt/scripts/%)  \
- $(if $(PATCH_WRAPPER),bin/patch-wrapper)
+ $(if $(PATCH_WRAPPER),bin/patch-wrapper)  \
+ test/run-test-completion
 
 dist : clean $(PACKAGE)-$(VERSION).tar.gz
 


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] Work around GNU patch limitation of patch format

2014-02-25 Thread Martin Quinson
I don't have no way to fix patch on the huge amount of machines where
it's already installed. I agree that the problem should be reported to
patch's maintainers, but having a workaround in the meanwhile sounds
like a good idea to me.

I'm not wearing my debian hat here, since this issue is easier to
solve in Debian that in the general case. My personal opinion is that
quilt as a project should be portable to as much systems as possible.

Mt 

On Tue, Feb 25, 2014 at 03:19:16PM +0100, Andreas Grünbacher wrote:
> Please no, let's fix patch instead.
> Am 25.02.2014 14:24 schrieb "Jean Delvare" :
> 
> > GNU patch is unable to deal with patch headers without timestamps if
> > a file name includes a space. Quilt currently generates such patches
> > if $QUILT_NO_DIFF_TIMESTAMPS is defined.
> >
> > In order to work around this limitation and always generate patches
> > that GNU patch will be able to apply, add a tab and a dash after the
> > file name in the patch header if $QUILT_NO_DIFF_TIMESTAMPS is set and
> > the file name contains a space.
> >
> > Originally I tried adding just a tab, and GNU patch was fine with
> > that, however the tailing tab was removed by "quilt refresh
> > --strip-trailing-whitespace" which many users have as a default
> > option. So I added a dash after the tab to protect it. I suppose it
> > could have been any other character, but that one worked. If you think
> > something else should be used instead, just let me know.
> > ---
> >  quilt/scripts/patchfns.in|8 
> >  test/space-in-filenames.test |   41
> > ++---
> >  2 files changed, 38 insertions(+), 11 deletions(-)
> >
> > --- quilt.orig/test/space-in-filenames.test 2014-02-24
> > 23:13:28.466215202 +0100
> > +++ quilt/test/space-in-filenames.test  2014-02-24 23:34:30.627834687 +0100
> > @@ -44,13 +44,13 @@ $ quilt diff -p ab
> >  > Index: b/a: b [c]
> >  > ===
> >  > --- /dev/null
> > -> +++ b/a: b [c]
> > +> +++ b/a: b [c]   -
> >  > @@ -0,0 +1 @@
> >  > +new line
> >  > Index: b/foo bar
> >  > ===
> > -> --- a/foo bar
> > -> +++ b/foo bar
> > +> --- a/foo bar-
> > +> +++ b/foo bar-
> >  > @@ -1 +1 @@
> >  > -foo
> >  > +bar
> > @@ -61,13 +61,13 @@ $ cat patches/test.diff
> >  > Index: b/a: b [c]
> >  > ===
> >  > --- /dev/null
> > -> +++ b/a: b [c]
> > +> +++ b/a: b [c]   -
> >  > @@ -0,0 +1 @@
> >  > +new line
> >  > Index: b/foo bar
> >  > ===
> > -> --- a/foo bar
> > -> +++ b/foo bar
> > +> --- a/foo bar-
> > +> +++ b/foo bar-
> >  > @@ -1 +1 @@
> >  > -foo
> >  > +bar
> > @@ -78,13 +78,13 @@ $ cat patches/test.diff
> >  > Index: b/a: b [c]
> >  > ===
> >  > --- /dev/null
> > -> +++ b/a: b [c]
> > +> +++ b/a: b [c]   -
> >  > @@ -0,0 +1 @@
> >  > +new line
> >  > Index: b/foo bar
> >  > ===
> > -> --- a/foo bar
> > -> +++ b/foo bar
> > +> --- a/foo bar-
> > +> +++ b/foo bar-
> >  > @@ -1 +1 @@
> >  > -foo
> >  > +bar
> > @@ -96,15 +96,34 @@ $ quilt grep new
> >  $ quilt grep " "
> >  > a: b [c]:new line
> >
> > +$ quilt pop -q
> > +> Removing patch patches/test.diff
> > +> No patches applied
> > +
> > +$ quilt patches foo
> > +$ quilt patches "foo bar"
> > +> patches/test.diff
> > +$ quilt patches bar
> > +$ quilt patches "foo bar baz"
> > +$ quilt patches 'a: b [c]'
> > +> patches/test.diff
> > +$ quilt patches a
> > +$ quilt patches b
> > +$ quilt patches 'a: b c'
> > +$ quilt patches "foo bar" 'a: b [c]'
> > +> patches/test.diff
> > +
> > +$ quilt push -q
> > +> Applying patch patches/test.diff
> > +> Now at patch patches/test.diff
> > +
> >  $ quilt remove "a: b [c]"
> >  > File a: b [c] removed from patch patches/test.diff
> >
> >  $ quilt files
> > -> foo
> >  > foo bar
> >
> >  $ quilt remove "foo bar"
> >  > File foo bar removed from patch patches/test.diff
> >
> >  $ quilt files
> > -> foo
> > --- quilt.orig/quilt/scripts/patchfns.in2014-02-24
> > 23:11:58.876431248 +0100
> > +++ quilt/quilt/scripts/patchfns.in 2014-02-24 23:38:02.564189493
> > +0100
> > @@ -731,6 +731,14 @@ diff_file()
> > || new_date=$'\t'"1970-01-01 00:00:00.0 +"
> > fi
> >
> > +   # Workaround for GNU patch which can't cope with no timestamps and
> > +   # spaces in file names at the same time
> > +   if [ -n "$QUILT_NO_DIFF_TIMESTAMPS" ]
> > +   then
> > +   [[ $old_hdr == *\ * ]] && old_date=$'\t'-
> > +   [[ $new_hdr == *\ * ]] && new_date=$'\t'-
> > +   fi
> > +
> > diff $QUILT_DIFF_OPTS \
> >  --label "$old_hdr$old_date" --label "$new_hdr$new

Re: [Quilt-dev] Changes file

2014-02-17 Thread Martin Quinson
On Mon, Feb 17, 2014 at 07:37:33PM +0100, Jean Delvare wrote:
> Hi all,
> 
> Can we get rid of quilt.changes? It's a pain to maintain, I keep
> forgetting adding entries to this file and I'm sure I'm not alone. And I
> think it's essentially redundant with git log.
> 
> I know we're using quilt.changes to feed the changelog in quilt.spec,
> but I don't think it makes any sense either. Rpm changelogs should
> contain high level user-visible change information and packaging change
> information, not a list of low level changes. That's what source code
> management tools are for.
> 
> In most projects I work on, we have given up on the per-commit changelog
> file long ago. I think a high level CHANGES file with entries grouped by
> area (rather than time line) is much more useful, for example
> lm-sensors' CHANGES file:
> 
> http://www.lm-sensors.org/browser/i2c-tools/trunk/CHANGES
> 
> But we could even go without a real-time CHANGES file at all, and
> user-visible changes are simply announced when a new version is released
> (and possibly stored in a CHANGES file for the record then.)

I always considered quilt.changes as a hard-to-read changelog. I would
also prefer maintaining a file that is useful to the users if possible.

I agree with you on the whole line, actually. 

Thanks, Mt.

-- 
This article does not deserve the paper and ink used to print it.
 -- Bastard Reviewer From Hell


signature.asc
Description: Digital signature
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 0/8] test/run: Cleanups and optimizations

2014-02-05 Thread Martin Quinson
On Wed, Feb 05, 2014 at 11:25:00AM +0100, Andreas Grünbacher wrote:
> This all sounds rather confused to me. Please leave those FUD
> arguments at home.

This is exactly as confused as the potential benefit that we could get
from that new tester in the context of quilt.

Bye, Mt.

-- 
Arguing with an engineer is a lot like wrestling in the mud with a pig.
After a couple of hours, you realize the pig likes it.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 0/8] test/run: Cleanups and optimizations

2014-02-05 Thread Martin Quinson
On Tue, Feb 04, 2014 at 11:32:56AM +0100, Andreas Grünbacher wrote:
> 2014-02-04 Martin Quinson :
> > I would see the use of a C program to test quilt as a regression,
> > personnally. We need quilt to be interpreted and not compiled in
> > Debian, or it becomes really difficult for us to use it as we
> > currently do.
> 
> You run the test suite when building the package, not when installing it, 
> right?

Yes, that's correct. But I'm still reluctant to ensure that a part of
the infrastructure is possibly not testable on all platforms due to
some obscure bug in the toolchain that would get unoticed until we
need the testing program.

Moreover, there is a new debian toy allowing to write tests that are
run on the installed package (not in the source tree) to increase the
software quality. I'm not using it yet, but I'd prefer not to do
anything that would prevent this to happen without a reason.

And you didn't tell us what the benefit of this tool would be for
quilt, or did I miss something maybe?

Thanks,
Mt.

-- 
Reject: Figure 3 is unclear.-- Bastard Reviewer From Hell

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 0/8] test/run: Cleanups and optimizations

2014-02-04 Thread Martin Quinson
Hello,

On Sun, Feb 02, 2014 at 11:42:45PM +0100, Andreas Grünbacher wrote:
> Jean,
> 
> just a heads up, I wrote a utility called exxe which could eventually
> replace the run script if a few more features are added. It's written in C,
> and relatively simple and fast. Maybe we want to switch to that at some
> point.

I would see the use of a C program to test quilt as a regression,
personnally. We need quilt to be interpreted and not compiled in
Debian, or it becomes really difficult for us to use it as we
currently do.

What are the new features that could benefit to quilt? The ability to
run remotely is not really related to our concern, is it?

Bye, Mt.

>   http://git.drbd.org/gitweb.cgi?p=exxe.git
> 
> I originally wrote this for the drbd test suite where we need to run
> various commands on various cluster nodes, send them stdin input, and
> capture their stdout, stderr, and exit status. The test suite keeps an ssh
> connection open to each cluster node; it uses this connection for running
> commands on the cluster node.
> 
> The test suite itself (http://git.drbd.org/gitweb.cgi?p=drbd-test.git) is a
> bit of a shell hell, but there are enough test cases in exxe itself to
> easily understand how exxe works without having to understand the drbd test
> suite.
> 
> Andreas

-- 
Combien il est doux d'obéir, lorsque nous pouvons réaliser le bonheur,
d'être convenablement déchargés, par de sages et dignes guides, de la
pesante responsabilité d'une direction générale de notre conduite.
  ---  Herbert Marcuse, in «Raison et Révolution»

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH v2] configure: add compat symlinks for cp and md5sum

2014-01-21 Thread Martin Quinson
Applied, many thanks. Actually, I intended to apply your previous
version and remove the gcp from the default choices myself, but you
were faster than me. Thanks for that.

Bye, Mt.

On Mon, Jan 20, 2014 at 11:44:03AM -0600, Kent R. Spillner wrote:
> Allow distributors to provide compat symlinks for cp and md5sum on
> non-GNU systems.  md5sum is used by quilt/scripts/inspect and is
> provided by GNU coreutils, but may be installed as gmd5sum on some
> systems (e.g. OpenBSD).  quilt/scripts/backup-files invokes cp
> with some non-portable GNU-specific command line arguments
> (e.g. --parents --remove-destination --target-directory).
> 
> Original diff from Jérémie Courrèges-Anglas  on
> OpenBSD ports mailing list.
> 
> Reported-by: Jérémie Courrèges-Anglas 
> Signed-off-by: Kent R. Spillner 
> ---
>  Makefile.in  | 2 ++
>  configure.ac | 3 +++
>  2 files changed, 5 insertions(+)
> 
> diff --git a/Makefile.in b/Makefile.in
> index 5438e6e..8fa7e82 100644
> --- a/Makefile.in
> +++ b/Makefile.in
> @@ -42,6 +42,8 @@ MSGCAT :=   @MSGCAT@
>  DIFFSTAT :=  @DIFFSTAT@
>  RPMBUILD :=  @RPMBUILD@
>  SENDMAIL :=  @SENDMAIL@
> +CP :=@CP@
> +MD5SUM :=@MD5SUM@
>  
>  USE_NLS :=   @USE_NLS@
>  STAT_HARDLINK := @STAT_HARDLINK@
> diff --git a/configure.ac b/configure.ac
> index 31fa628..385c17c 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -367,6 +367,9 @@ fi
>  
>  QUILT_COMPAT_PROG_PATH(SENDMAIL, sendmail, [], [/usr/sbin])
>  
> +QUILT_COMPAT_PROG_PATH(CP, cp, [cp])
> +QUILT_COMPAT_PROG_PATH(MD5SUM, md5sum, [gmd5sum md5sum])
> +
>  AC_PATH_PROG(MSGMERGE, [msgmerge])
>  AC_PATH_PROG(MSGFMT, [msgfmt])
>  AC_PATH_PROG(XGETTEXT, [xgettext])
> -- 
> 1.8.4.5
> 
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
A couple of months in the laboratory frequently save a couple of hours
in the library. -- old scientists saying

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 1/5] Exit with an error when diffs retcode=2 (error) on patch refresh

2014-01-19 Thread Martin Quinson
On Sun, Jan 19, 2014 at 09:41:51AM +0100, Jean Delvare wrote:

> You didn't test this new version of the patch, did you? It doesn't pass
> the test suite...

Wooops, I'm not sure of what kind of mess I built here, sorry. It
seems that I intended to build the debian package in one shell tab to
test everything, and to mail the patches in the other tab. Then, I
messed up and the task "send mails" didn't wait for the "build package
successfully" one. Sorry.

> I've made all the suggested fixes and changes myself and committed the
> patch under your name.

Many thanks for your support. I'll try to be more concentred next time
I send some patches...

Sorry, Mt.

-- 
Never trust someone who only codes in CAML or Haskell.
The way things are done matters more to him than the result.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 6/7] Exit with an error when diffs retcode=2 (error) on patch

2014-01-17 Thread Martin Quinson
Hello,

On Fri, Jan 17, 2014 at 10:11:47PM +0100, Jean Delvare wrote:
> 
> Hmm. We incorrectly assumed that portability of this construct wasn't an
> issue because we were using bash. We aren't. The tester is written in
> perl, and except for a few special cases, it blindly execs the commands
> in the test cases. So we get /usr/bin/printf called here, not bash's
> printf.
>
> I am using GNU coreutils 8.12 and 8.21 on my machine. I suppose you are
> using something else on your system.

Nope, I'm the same. But /bin/sh is an alias to dash here. That might
be why, as the runner script seems to use /bin/sh to start the
commands that need a shell (such as the ones with a redirection).

> $ bash -c "printf '\\x02\\x00\\x01'" > test.bin
> 
> Performance-wise it's suboptimal but I suppose we don't really care.

I did that, and it works. Yeah, the performance drop is not noticable
on this test file ;)

The new patch should be ready now. Stay tuned.

Bye, Mt.

-- 
C combines the power of assembler with the portability of assembler.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 6/7] Exit with an error when diffs retcode=2 (error) on patch

2014-01-17 Thread Martin Quinson
Hello,

On Sun, Jan 12, 2014 at 12:48:30PM +0100, Jean Delvare wrote:
> 
> On Sun, 29 Dec 2013 22:48:01 +0100, Martin Quinson wrote:

> > Description: Exit with an error when diff's retcode=2 (error) on patch
> 
> I am just realizing that the description seems to be truncated. I think
> you mean "on patch refresh"?

Erm, it was manually truncated (I did type it wrong) :/

> > Index: b/quilt/scripts/patchfns.in
> > ===
> > --- a/quilt/scripts/patchfns.in
> > +++ b/quilt/scripts/patchfns.in
> > @@ -766,6 +766,12 @@
> 
> Can you please generate your patches with diff option -p in the future?
> I makes reviewing easier.

I need to investigate because it should be the case accordign to my
settings.

> > +   $ quilt refresh
> > +   > diff: test.txt: Permission denied
> > +   > Diff failed on file 'test.txt', aborting.
> 
> Please check the return value here:
> 
>   $ echo %{?}
>   > 1

It does not work for me. If I use %{?}, it echoes ?. If I use $? it
echoes 0. And looking at test/run, I don't see where the return value
of the child command should be set into $?. No other test check the
return value of the commands. test/conflicts.test should do that but
doesnt.

> BTW, the return value of "quilt diff" in case a binary file is included
> is still 0. I think it needs to be fixed as well,

Not sure about it actually. quilt diff kinda works on binary, doesn't
it?

Bye, Mt.

-- 
A theory is falsifiable [(and therefore scientific) only] if the
class of its potential falsifiers is not empty.
 -- Sir Karl Popper _The Logic of Scientific Discovery_ §21

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 6/7] Exit with an error when diffs retcode=2 (error) on patch

2014-01-17 Thread Martin Quinson
Hello Jean,

On Sun, Jan 12, 2014 at 12:28:37PM +0100, Jean Delvare wrote:
> 
> > But unfortunately, I fail to put your idea into practice because I
> > fail to get the right parsing in the test file. If the test file reads
> > $ printf "\x02\x00\x01" > test
> > I get x02x00x01 in the diff. I tried several combination, in vain.
> > 
> > Jean, you just rewrote the main loop and variable substitution parts
> > of test/run. Do you have an idea of how to fix that too, please?
> 
> Well, just doubling the backslashes did the trick for me. The following
> test case works for me (bash versions 3.2.51 and 4.2.45):
> 
>   $ printf "\\x02\\x00\\x01" > test.bin
> 
>   $ quilt new test2.diff
>   > Patch %{P}test2.diff is now on top
>   $ quilt add test.bin
>   > File test.bin added to patch %{P}test2.diff
> 
>   $ printf "\\x03\\x00\\x01" > test.bin
>   $ quilt diff -pab --no-index
>   >~ (Files|Binary files) a/test\.bin and b/test\.bin differ
> 
> Does it not work for you?

Nope. It gives me the following, where the printf argument is written
textually but not interpreted (bash 4.2.45).

[33] $ quilt diff -pab --no-index -- failed
--- a/test.bin!~ (Files|Binary files) a/test\.bin and 
b/test\.bin differ
+++ b/test.bin!= ~
@@ -1 +1 @@   != ~
-\x02\x00\x01 != ~
\ No newline at end of file   != ~
+\x03\x00\x01 != ~
\ No newline at end of file   != ~

I'm quite puzzled, I must admit. Just in case, my patch is here:
http://anonscm.debian.org/gitweb/?p=collab-maint/quilt.git;a=blob;f=debian/patches/diff_exit_code;h=8c90d5384fa9962b71107b98eea145addd22514b;hb=HEAD

Sorry, Mt

-- 
L'informatique soit ça marche pas, soit ca marchait avant qu'on y touche.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH, RFC] Stop using patch option -E

2013-12-30 Thread Martin Quinson
Hello Jean,

could we maybe push that change? We decided last year that it was
reasonable and should be commited. What kind of documentation do you
want to write? I could maybe help here.

Bye, Mt.

PS: sorry for flooding your mailbox like this every chrismas vacations ;)

On Wed, Dec 19, 2012 at 10:06:49AM +0100, Jean Delvare wrote:
> Hi Andreas,
> 
> Thanks for the fast reply.
> 
> Le mardi 18 décembre 2012 à 19:06 +0100, Andreas Grünbacher a écrit :
> > Jean,
> > 
> > 2012/12/18 Jean Delvare :
> > > GNU patch version 2.7 and newer deals just fine with empty files,
> > > however our use of option -E breaks this feature. So stop using this
> > > option. Anyway, the manual page says: "Normally this option is
> > > unnecessary" and the test suite passes just fine without it.
> > >
> > > Andreas, can you remember why we were using option -E? I dug the history
> > > but apparently it has been there since the beginning so I couldn't find
> > > an explanation.
> > 
> > when patch is in POSIX mode or the patch format doesn't allow to distinguish
> > empty files from deleted files, patch deletes empty files only if the -E 
> > option
> > is given. If the -E option is given, patch always deletes empty files.
> > 
> > So if you want to use the -E option or not depends on which kinds of patches
> > you use: with "modern" unified or context diffs as generated by GNU diff or 
> > git,
> > you usually don't want -E; with other patch formats, you usually do want -E.
> > 
> > So I think your change makes sense; if people want -E, they can put it in
> > $QUILT_PATCH_OPTS.
> 
> That was exactly my thought. It's easier to add an option you want to
> $QUILT_PATCH_OPTS than to remove one that was hard-coded into quilt.
> 
> > > I suppose it may help get files deleted when using
> > > QUILT_NO_DIFF_TIMESTAMPS? But OTOH I would hope that GNU patch notices
> > > when the file name is /dev/null and acts appropriately.
> > 
> > Yes it does; the timestamps are not needed for that.
> 
> Thanks for the confirmation, the patch manual page did not make it
> completely clear. I'll do some more tests and if everything looks
> correct I'll just commit this change, with additional documentation.
> 
> -- 
> Jean Delvare
> Suse L3
> 
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
SYNONYME n.m.: Mot à écrire à la place de celui dont on n'est pas
certain de l'orthographe.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 6/7] Exit with an error when diffs retcode=2 (error) on patch

2013-12-30 Thread Martin Quinson
On Mon, Dec 30, 2013 at 08:52:20AM +0100, Raphael Hertzog wrote:
> On Sun, 29 Dec 2013, Martin Quinson wrote:
> > I took all of your suggestions and added a small test case. It does
> > not test what happens with binary diffs because I could not think of
> > how to generate a binary file in a portable manner, but uses chmod -r.
> 
> Maybe something like this ?
> 
> printf "\x02\x00\x01" >binary
> 
> I don't know if that construct is portable, but printf should be.

That's a good idea! And yes, it is portable, as we use
printf for every message that must be translated, as in 

  printf $"File %s not found\n" "$tarball"

If we do $"File $tarball not found\n", the filename is expended before
we look into translation catalog, defeating the lookup.
it is not portable, but we do depend on bash


But unfortunately, I fail to put your idea into practice because I
fail to get the right parsing in the test file. If the test file reads
$ printf "\x02\x00\x01" > test
I get x02x00x01 in the diff. I tried several combination, in vain.

Jean, you just rewrote the main loop and variable substitution parts
of test/run. Do you have an idea of how to fix that too, please?

Thanks for your time,
Mt

-- 
L'ensemble des personnes ayant un nombre d'Erdős infini est dense dans la 
population.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 6/7] Exit with an error when diffs retcode=2 (error) on patch

2013-12-29 Thread Martin Quinson
Hello Jean,

I took all of your suggestions and added a small test case. It does
not test what happens with binary diffs because I could not think of
how to generate a binary file in a portable manner, but uses chmod -r.

The new patch is inline here while the old one is below, quoted in the
mail for reference.

Bye, Mt.

Description: Exit with an error when diff's retcode=2 (error) on patch
 This is trigered e.g. when you try to add a binary file to a patch.
 This is actually creepy to think that we were not checking the
 retcode of diff :)
Forwarded: 2013-12-29
Bug-Debian: http://bugs.debian.org/638313
Author: Martin Quinson

---
 quilt/refresh.in  |2 +-
 quilt/scripts/patchfns.in |6 ++
 test/faildiff.test|   18 ++
 3 files changed, 25 insertions(+), 1 deletion(-)
 
pipestatus: 1  
Index: b/quilt/scripts/patchfns.in
===
--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -766,6 +766,12 @@
echo "$line"
cat
fi
+
+   # Test the return value of diff, and propagate the error retcode if any
+   if [ ${PIPESTATUS[0]} == 2 ]
+   then
+   return 1
+   fi
 }
 
 cat_file()
Index: b/quilt/refresh.in
===
--- a/quilt/refresh.in
+++ b/quilt/refresh.in
@@ -231,7 +231,7 @@
fi
if ! diff_file "$file" "$old_file" "$new_file"
then
-   printf $"Diff failed, aborting\n" >&2
+   printf $"Diff failed on file '%s', aborting.\n" "$new_file" >&2
die 1
fi
 
Index: b/test/faildiff.test
===
--- /dev/null
+++ b/test/faildiff.test
@@ -0,0 +1,18 @@
+   $ mkdir patches
+
+   $ cat > test.txt
+   < This is test.txt.
+
+   $ quilt new test.diff
+   > Patch %{P}test.diff is now on top
+
+   $ quilt add test.txt
+   > File test.txt added to patch %{P}test.diff
+
+   $ chmod -r test.txt
+
+   $ quilt refresh
+   > diff: test.txt: Permission denied
+   > Diff failed on file 'test.txt', aborting.
+
+   $ chmod +r test.txt


On Sun, Dec 22, 2013 at 10:31:06AM +0100, Jean Delvare wrote:
> Hi Martin,
> 
> On Sat, 21 Dec 2013 21:27:58 +0100, martin.quin...@loria.fr wrote:
> > Description:
> >  This is trigered e.g. when you try to add a binary file to a patch.
> >  This is actually creepy to think that we were not checking the
> >  retcode of patch :)
> 
> You mean diff, not patch, right?
> 
> > Forwarded: 2013-12-21
> > Bug-Debian: http://bugs.debian.org/638313
> > Author: Martin Quinson
> > 
> > ---
> >  quilt/refresh.in  |2 +-
> >  quilt/scripts/patchfns.in |6 ++
> >  2 files changed, 7 insertions(+), 1 deletion(-)
> >  
> > pipestatus: 1  
> > Index: b/quilt/scripts/patchfns.in
> > ===
> > --- a/quilt/scripts/patchfns.in
> > +++ b/quilt/scripts/patchfns.in
> > @@ -766,6 +766,12 @@
> > echo "$line"
> > cat
> > fi
> > +
> > +   # Test the return value of diff, and propagate the error retcode if any
> > +   if [ ${PIPESTATUS[0]} == 2 ] ;
> 
> The semi-colon is not needed.
> 
> > +   then
> > +   return 1
> > +   fi
> >  }
> >  
> >  cat_file()
> > Index: b/quilt/refresh.in
> > ===
> > --- a/quilt/refresh.in
> > +++ b/quilt/refresh.in
> > @@ -231,7 +231,7 @@
> > fi
> > if ! diff_file "$file" "$old_file" "$new_file"
> > then
> > -   printf $"Diff failed, aborting\n" >&2
> > +   printf $"Diff failed on '$new_file', aborting. Is it a binary 
> > file?\n" >&2
> 
> I don't think it is a good idea to suggest a reason when the problem
> could be completely different. It adds confusion more than it helps.
> 
> If you want to be able to report this specific case then you should
> grep for '^Binary files' in the output of diff, although this could be
> fragile.
> 
> > die 1
> > fi
> >  
> 
> I also would like you to add a test case for this in the test suite.
> 
> Thanks,
> -- 
> Jean Delvare
> Suse L3 Support

-- 
Avant d'installer linux, mon ordinateur plantait tout le temps, les
filles me fuyaient, je n'avais pas d'amis ni de vie sociale, et
j'avais des boutons. Maintenant, mon ordinateur ne plante plus.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 7/7] add --select option to mail command

2013-12-29 Thread Martin Quinson
Hello,

On Sun, Dec 22, 2013 at 10:47:36AM +0100, Jean Delvare wrote:
> 
> So I think you can just drop this patch.

I did that, indeed.

Thanks for your expertise, Mt.

-- 
Computers make very fast, very accurate mistakes.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] Substitute sed with configured path

2013-12-24 Thread Martin Quinson
Hello,

thanks for this patch. 

I have one question, out of curiosity. Why do you set SED to @SED@ and
then call $SET. Wouldn't it be more efficient to directly call @SED@ ?

I mean that instead of doing that:
> -  | sed -nre "s,^300 \`(/proc/.*/fd)/.*' -> \`$patch'$,\\1,p")
> +  | $SED -nre "s,^300 \`(/proc/.*/fd)/.*' -> \`$patch'$,\\1,p")
I would do that:
> +  | @SED@ -nre "s,^300 \`(/proc/.*/fd)/.*' -> \`$patch'$,\\1,p")

Do I miss something here?

Thanks again for this patch, that's a pity that our --with-sed option
was not functionnal.

Bye, Mt.

On Tue, Dec 24, 2013 at 08:42:57AM -0600, Kent R. Spillner wrote:
> configure.ac calls QUILT_COMPAT_PROG_PATH(SED, sed)
> allowing users to provide their own path to sed via
> --with-sed=.  However, nothing was actually using SED.
> This patch updates Makefile.in to substitute @SED@ in
> all .in files, and updates everything in bin/ and quilt/
> to actually support this substitution.
> 
> With this change it is possible to configure quilt to
> explicitly use GNU sed on systems where GNU sed is
> available but not installed by default (e.g. OpenBSD).
> 
> Signed-off-by: Kent R. Spillner 
> ---
>  Makefile.in   |  1 +
>  bin/patch-wrapper.in  |  5 +++--
>  bin/quilt.in  |  4 +++-
>  quilt/annotate.in |  6 --
>  quilt/diff.in |  4 +++-
>  quilt/grep.in |  4 +++-
>  quilt/header.in   |  4 +++-
>  quilt/import.in   |  4 +++-
>  quilt/mail.in | 24 +---
>  quilt/refresh.in  |  4 +++-
>  quilt/scripts/inspect.in  |  4 +++-
>  quilt/scripts/patchfns.in | 18 ++
>  quilt/setup.in|  8 +---
>  13 files changed, 57 insertions(+), 33 deletions(-)
> 
> diff --git a/Makefile.in b/Makefile.in
> index 8040653..cd7c2b9 100644
> --- a/Makefile.in
> +++ b/Makefile.in
> @@ -257,6 +257,7 @@ $(patsubst %.in,%,$(wildcard bin/*.in quilt/*.in 
> quilt/scripts/*.in)) :: Makefil
>   -e 's:@PERL''@:$(PERL):g'   \
>   -e 's:@BASH''@:$(BASH):g'   \
>   -e 's:@PATCH''@:$(PATCH):g' \
> + -e 's:@SED''@:$(SED):g' \
>   -e 's:@STAT_HARDLINK''@:$(STAT_HARDLINK):g' \
>   -e 's:@VERSION''@:$(VERSION):g' \
>   -e 's:@RELEASE''@:$(RELEASE):g' \
> diff --git a/bin/patch-wrapper.in b/bin/patch-wrapper.in
> index 358856a..489fbca 100755
> --- a/bin/patch-wrapper.in
> +++ b/bin/patch-wrapper.in
> @@ -7,6 +7,7 @@
>  # used directly, and no quilt metadata will get created.
>  
>  PATCH=@PATCH@
> +SED=@SED@
>  original_options=("$@")
>  
>  # GNU patch recognizes these environment variables
> @@ -69,9 +70,9 @@ find_pipe_patch() {
>  patch=${patch//\[/\\[}
>  patch=${patch//\]/\\]}
>  set -- $(stat -c $'%a %N\n' /proc/*/fd/* 2>/dev/null \
> -  | sed -nre "s,^300 \`(/proc/.*/fd)/.*' -> \`$patch'$,\\1,p")
> +  | $SED -nre "s,^300 \`(/proc/.*/fd)/.*' -> \`$patch'$,\\1,p")
>  set -- $(stat -c $'%a %N\n' $1/* 2>/dev/null \
> -  | sed -nre "s,^500 \`.*' -> \`(.*)',\\1,p")
> +  | $SED -nre "s,^500 \`.*' -> \`(.*)',\\1,p")
>  [ $# -eq 1 ] || set -- "$patch"
>  echo "$1"
>  }
> diff --git a/bin/quilt.in b/bin/quilt.in
> index 2271833..51773a3 100644
> --- a/bin/quilt.in
> +++ b/bin/quilt.in
> @@ -6,6 +6,8 @@
>  #
>  #  See the COPYING and AUTHORS files for more details.
>  
> +SED=@SED@
> +
>  # unset posix strict conformance variable since patch cannot be run
>  # non-interactively when it's set.
>  unset POSIXLY_CORRECT
> @@ -44,7 +46,7 @@ usage()
>   quilt_commands \
>   | sort \
>   | column | column -t \
> - | sed -e $'s/^/\t/'
> + | $SED -e $'s/^/\t/'
>   echo $"
>  Global options:
>  
> diff --git a/quilt/annotate.in b/quilt/annotate.in
> index 0366f5a..c71e02b 100644
> --- a/quilt/annotate.in
> +++ b/quilt/annotate.in
> @@ -6,6 +6,8 @@
>  #
>  #  See the COPYING and AUTHORS files for more details.
>  
> +SED=@SED@
> +
>  # Read in library functions
>  if [ "$(type -t patch_file_name)" != function ]
>  then
> @@ -40,7 +42,7 @@ empty_file()
>  {
>   local file=$1
>   [ -s "$file" ] \
> - && sed -e 's:.*::' "$file"
> + && $SED -e 's:.*::' "$file"
>  }
>  
>  annotation_for()
> @@ -140,7 +142,7 @@ fi
>  
>  if [ ${#patches[@]} = 0 ]
>  then
> - sed -e 's:^:'$'\t'':' "${files[${#files[@]}-1]}"
> + $SED -e 's:^:'$'\t'':' "${files[${#files[@]}-1]}"
>   exit 0
>  fi
>  
> diff --git a/quilt/diff.in b/quilt/diff.in
> index 6b4f9d6..4894fff 100644
> --- a/quilt/diff.in
> +++ b/quilt/diff.in
> @@ -6,6 +6,8 @@
>  #
>  #  See the COPYING and AUTHORS files for more details.
>  
> +SED=@SED@
> +
>  # Read in library functions
>  if [ "$(type -t patch_file_name)" != function ]
>  then
> @@ -82,7 +84

Re: [Quilt-dev] [patch 5/7] unset GREP_OPTIONS at startup

2013-12-22 Thread Martin Quinson
Hello,

- Mail original -
> Hi Martin,
> 
> On Sat, 21 Dec 2013 21:27:57 +0100, martin.quin...@loria.fr wrote:
> > Description:
> >   It is too easy to break quilt with some strange GREP_OPTIONS, so
> >   ignore it.
> > Bug-Debian: http://bugs.debian.org/715563
>  
[...]

> Looks good, please commit.

Done. Thanks for your time.
Mt.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 7/7] add --select option to mail command

2013-12-21 Thread martin . quinson
Description:
 .
 When you want to only send out part of a series, this is not
 trivial with quilt. This patch adds a --select option to the
 mail command to allow editing a copy of the series file before
 sending mail so that only those patches you keep in that file
 are sent.
Origin: vendor
Author: Johannes Berg 
Reviewed-by: Martin Quinson 
Last-Update: 2013-08-05
Bug-Debian: http://bugs.debian.org/481331

---
 quilt/mail.in |   30 --
 1 file changed, 24 insertions(+), 6 deletions(-)

Index: b/quilt/mail.in
===
--- a/quilt/mail.in
+++ b/quilt/mail.in
@@ -21,7 +21,7 @@
 
 usage()
 {
-   printf $"Usage: quilt mail {--mbox file|--send} [-m text] [-M file] 
[--prefix prefix] [--sender ...] [--from ...] [--to ...] [--cc ...] [--bcc ...] 
[--subject ...] [--reply-to message] [first_patch [last_patch]]\n"
+   printf $"Usage: quilt mail {--mbox file|--send} [--select] [-m text] 
[-M file] [--prefix prefix] [--sender ...] [--from ...] [--to ...] [--cc ...] 
[--bcc ...] [--subject ...] [--reply-to message] [first_patch [last_patch]]\n"
if [ x$1 = x-h ]
then
printf $"
@@ -68,6 +68,9 @@
 
 --reply-to message
Add the appropriate headers to reply to the specified message.
+
+--select
+   Edit a copy of the series file to select patches to send.
 " "@DOCSUBDIR@/README.MAIL"
exit 0
else
@@ -165,7 +168,7 @@
 options=`getopt -o m:M:h \
--long from:,to:,cc:,bcc:,subject: \
--long send,mbox:,charset:,sender: \
-   --long prefix:,reply-to:,signature: -- "$@"`
+   --long select,prefix:,reply-to:,signature: -- "$@"`
 
 if [ $? -ne 0 ]
 then
@@ -223,6 +226,9 @@
--send)
opt_send=1
shift ;;
+   --select)
+   opt_select=1
+   shift ;;
--mbox)
opt_mbox=$2
shift 2 ;;
@@ -262,6 +268,10 @@
 
 if [ $# -ge 1 ]
 then
+   if [ -n "$opt_select" ] ; then
+   echo $"Cannot use --select when specifying the first and last 
patch to work with."
+   exit 1
+   fi
if [ "$1" = - ]
then
first_patch="$(find_first_patch)" || exit 1
@@ -415,6 +425,9 @@
}
 fi
 
+tmpdir=$(gen_tempfile -d)
+add_exit_handler "rm -rf $tmpdir"
+
 if [ -n "$first_patch" ]
 then
if [ -n "$last_patch" ]
@@ -436,14 +449,19 @@
else
patches=( "$first_patch" $(patches_after "$first_patch") )
fi
-else
+elif [ -n "$opt_select" ] ; then
+   nser="$tmpdir/series"
+   cp "$SERIES" "$nser"
+   if ! $EDITOR "$nser" ; then
+   exit 1
+   fi
+   SERIES="$nser"
+   patches=( $(cat_series) )
+else   
patches=( $(cat_series) )
 fi
 total=${#patches[@]}
 
-tmpdir=$(gen_tempfile -d)
-add_exit_handler "rm -rf $tmpdir"
-
 for patch in "${patches[@]}"
 do
mkdir -p "$tmpdir/$(dirname "$patch")"


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 6/7] Exit with an error when diffs retcode=2 (error) on patch

2013-12-21 Thread martin . quinson
Description:
 This is trigered e.g. when you try to add a binary file to a patch.
 This is actually creepy to think that we were not checking the
 retcode of patch :)
Forwarded: 2013-12-21
Bug-Debian: http://bugs.debian.org/638313
Author: Martin Quinson

---
 quilt/refresh.in  |2 +-
 quilt/scripts/patchfns.in |6 ++
 2 files changed, 7 insertions(+), 1 deletion(-)
 
pipestatus: 1  
Index: b/quilt/scripts/patchfns.in
===
--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -766,6 +766,12 @@
echo "$line"
cat
fi
+
+   # Test the return value of diff, and propagate the error retcode if any
+   if [ ${PIPESTATUS[0]} == 2 ] ;
+   then
+   return 1
+   fi
 }
 
 cat_file()
Index: b/quilt/refresh.in
===
--- a/quilt/refresh.in
+++ b/quilt/refresh.in
@@ -231,7 +231,7 @@
fi
if ! diff_file "$file" "$old_file" "$new_file"
then
-   printf $"Diff failed, aborting\n" >&2
+   printf $"Diff failed on '$new_file', aborting. Is it a binary 
file?\n" >&2
die 1
fi
 


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 2/7] verbose error message when the serie file does not exist

2013-12-21 Thread martin . quinson
Description:
 patchfns.in(cat_series): Displays an error message when the $SERIES
 file does not exist, and when run  in verbose mode.
Bug-Debian: http://bugs.debian.org/369908 
Upstream-status: submitted 2013-12-21

---
 quilt/scripts/patchfns.in |3 +++
 1 file changed, 3 insertions(+)

Index: b/quilt/scripts/patchfns.in
===
--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -329,6 +329,9 @@
sed -e '/^#/d' -e 's/^[ '$'\t'']*//' \
-e 's/[ '$'\t''].*//' -e '/^$/d' $SERIES
else
+   if [ "$opt_verbose" ]; then
+   echo $"No series file found\n" >&2
+   fi
return 1
fi
 }


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 4/7] Informative message when using graph without graphviz

2013-12-21 Thread martin . quinson
Description:
 Previously, trying to use the graph subcommand without graphviz being
 installed resulted in a cryptic error message: 
 .
 Can't exec "tred": No such file or directory at /usr/lib/perl/5.14/IO/File.pm 
line 66,  line 1.
 .
 graphviz is already in the Suggests field of the debian package, and
 we cannot raise this dependency severity given the central role of
 quilt in the debian infrastructure. This informative error message is
 much more sensible.
Author: Martin Quinson 
Bug-Debian: http://bugs.debian.org/659944
Forwarded: 2013-12-21

---
 quilt/graph.in |7 +++
 1 file changed, 7 insertions(+)

Index: b/quilt/graph.in
===
--- a/quilt/graph.in
+++ b/quilt/graph.in
@@ -17,6 +17,13 @@ then
. $QUILT_DIR/scripts/patchfns
 fi
 
+whichtred=`which /usr/bin/tred`
+if [ -z "$whichtred" ]
+then
+   echo $"It seems that graphviz is currently not installed (unable to 
find the tred binary). You must install it to use 'quilt graph'."
+   exit 1
+fi
+
 usage()
 {
printf $"Usage: quilt graph [--all] [--reduce] [--lines[=num]] 
[--edge-labels=files] [-T ps] [patch]\n"


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 1/7] allow mail command to grab the mail title from dep3 formalism

2013-12-21 Thread martin . quinson
Description:
 If the patch is formatted according to http://dep.debian.net/deps/dep3/ 
 then the mail subcommand will manage to extract a mail subject and
 description out of this formalism.
Forwarded: Sent 2013-12-21

---
 quilt/mail.in |   22 +++---
 1 file changed, 19 insertions(+), 3 deletions(-)

Index: b/quilt/mail.in
===
--- a/quilt/mail.in
+++ b/quilt/mail.in
@@ -338,6 +338,18 @@
' $tmpdir/patch > $tmpdir/body
fi
 
+   # Does this patch have a Description: block?
+   if [ -z "$subject" ]
+   then
+   subject=$(formail -x Description: < $tmpdir/header 
|head -n 1)
+   if [ -n "$subject" ]
+   then
+   # Get all dep3 pseudo-headers (but the first 
line of the description, already used as a subject)
+   # into the body of the generated mail, plus the 
patch.
+   sed -e 's/^Description:.*$/Description:/' 
$tmpdir/patch > $tmpdir/body
+   fi
+   fi
+
# Does this patch have DESC // subject // EDESC?
if [ -z "$subject" ]
then
@@ -442,10 +454,14 @@
subject=$(formail -x Replace-Subject: < "$tmpdir/$patch" | join_lines)
if [ $status -ne 0 -o -z "$subject" ]
then
-   printf \
+   subject=$(formail -x Description: < "$tmpdir/$patch" | head -n 
1)
+   if [ $status -ne 0 -o -z "$subject" ]
+   then
+   printf \
 $"Unable to extract a subject header from %s\n" "$(print_patch "$patch")" >&2
-   rm -rf $tmpdir
-   exit 1
+   rm -rf $tmpdir
+   exit 1
+   fi
fi
subjects[${#subjects[@]}]="$patch"$'\t'"$subject"
 done


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 0/7] Some more patches from Debian

2013-12-21 Thread martin . quinson
Hello,

here is another bunch of patches that I had in the Debian package.

I feel that these patches are not really controversial, and I hope
that you guys will like them. I did not trust myself to commit them,
I'm waiting for your approval before doing so. But if you commit them
yourself, even better.

Once we are ok on these 7 easy patches, I have 5 other patches in
Debian, but they are ... less easy, so I keep them for 2014.

Thanks for your time & happy chrismas and everything,
Mt.



___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 5/7] unset GREP_OPTIONS at startup

2013-12-21 Thread martin . quinson
Description:
  It is too easy to break quilt with some strange GREP_OPTIONS, so ignore it.
Bug-Debian: http://bugs.debian.org/715563
Forwarded: 2013-12-21
Author: Martin Quinson

---
 bin/quilt.in |4 
 1 file changed, 4 insertions(+)

Index: b/bin/quilt.in
===
--- a/bin/quilt.in
+++ b/bin/quilt.in
@@ -10,6 +10,10 @@
 # non-interactively when it's set.
 unset POSIXLY_CORRECT
 
+# unset GREP_OPTIONS as it's quite easy to break quilt with uncommon options
+# see http://bugs.debian.org/715563
+unset GREP_OPTIONS
+
 export TEXTDOMAIN=quilt
 export TEXTDOMAINDIR=@LOCALEDIR@
 


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 3/7] setup dont obey the settings of any englobing .pc

2013-12-21 Thread martin . quinson
Description:
 .
 This is mainly intended to get the setup.test working even if the
 debian package contains a .pc directory. Without this patch, the
 debian packaging stuff will get the testsuite using debian/patches
 instead of patches (because it's the way it goes in our .pc). The
 test breaks with that setting.
 .
 The patch changes the setup command to not take the settings of any
 .pc directory found, and reset QUILT_PC QUILT_PATCHES and QUILT_SERIES
 to their default values.
Bug-Debian: http://bugs.debian.org/573689
Forwarded: 2013-12-21

---
 quilt/setup.in |5 +
 1 file changed, 5 insertions(+)

Index: b/quilt/setup.in
===
--- a/quilt/setup.in
+++ b/quilt/setup.in
@@ -17,8 +17,13 @@
. $QUILT_DIR/scripts/patchfns
if [ -n "$SUBDIR" ]
then
+   # Damn, found an enclosing quilt directory; don't follow its 
settings
cd $SUBDIR
unset SUBDIR
+   unset QUILT_PC QUILT_PATCHES QUILT_SERIES
+   : ${QUILT_PC:=.pc}
+   : ${QUILT_PATCHES:=patches}
+   : ${QUILT_SERIES:=series}
fi
 fi
 


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH 0/3] Fixes and documentation for the test script

2013-12-21 Thread Martin Quinson
On Wed, Dec 18, 2013 at 02:08:55PM +0100, Jean Delvare wrote:
> [PATCH 1/3] test/run: Rewrite the main parsing loop
> [PATCH 2/3] test/run: Fix variable substitution
> [PATCH 3/3] test/run: Documentation update

Hello, 

I gave a quick look at your patches and they look good to me. I'm glad
you commited them already.

Thanks for your time,
Mt

-- 
It is impossible to travel faster than light, and certainly not desirable,
as one's hat keeps blowing off. -- Woody Allen.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 2/5] Return 2 (instead of 1) when there is nothing to do

2013-12-21 Thread Martin Quinson
Hello Jean,

On Tue, Dec 17, 2013 at 03:30:13PM +0100, Jean Delvare wrote:
> Hi Martin,
> 
> Sorry for the delay, I have finally made up my mind, cleaned up the
> patches, and applied them all.

I've reviewed your changes, and that makes us another patch less in
the debian package. Yuhu! I only have 12 patches now :) I'll submit
some of them soon.

Thanks for your time,
Mt.

-- 
The practical effectiveness of the algorithm may be somewhat overstated
since the experimental results prove its inability to fulfill its goals.
 -- Bastard Reviewer From Hell

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 4/5] verbosly die if /proc is not mounted

2013-12-21 Thread Martin Quinson
On Tue, Dec 17, 2013 at 03:38:33PM +0100, Jean Delvare wrote:
> Hi Martin,
> 
> Le Wednesday 19 December 2012 à 15:35 +0100, martin.quin...@loria.fr a
> écrit :
> > --- a/bin/patch-wrapper.in
> > +++ b/bin/patch-wrapper.in
> > @@ -171,6 +171,10 @@ then
> >  if [ -n "$opt_input" ]
> >  then
> > patch=$opt_input
> > +elif [ ! -e /proc/self ]
> > +then
> > +echo "patch-wrapper: /proc not mounted!" >&2
> > +   exit 1
> >  elif [ -e /proc/self/fd/0 ]
> >  then
> > patch=$(readlink /proc/self/fd/0)
> 
> I have no idea what patch-wrapper is good for, I don't use it. So I
> can't have any objection or useful comment about the change above. Feel
> free to commit it if you need that change. Please just fix the
> indentation before you do so ;-)

Done. (it's very helpful to detect that your chroot does not have
/proc mounted).

One patch less in debian \o/ 

Bye, Mt.

-- 
Oh, I am a C programmer and I'm okay. 
I muck with indices and structs all day. 
And when it works, I shout hoo-ray. 
Oh, I am a C programmer and I'm okay.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] scripts: let users override LESS env variable.

2013-12-16 Thread Martin Quinson
On Mon, Dec 16, 2013 at 01:21:51PM +0100, Jean Delvare wrote:
> Le Saturday 14 December 2013 à 13:29 -0600, Kent R. Spillner a écrit :
> > On Sat, Dec 14, 2013 at 02:28:49PM +0100, Jean Delvare wrote:
> > > I do not understand the value of this change. How is it better to set
> > > QUILT_LESS_ARGS in ~/.quiltrc than to set LESS in ~/.quiltrc?
> > > 
> > > As far as I can see, the feature was already there, just not documented.
> > > If I'm missing something, please explain.
> > 
> > I wouldn't say it is better.  I wanted to disable the behavior of less -F
> > but quilt's use of LESS wasn't documented.  I chose to add QUILT_LESS_ARGS
> > simply to be consistent with other Quilt env variables, and also to be
> > consistent with other tools that page their output (e.g. MANPAGER, 
> > GIT_PAGER,
> > etc.).  If you wish to revert my change and simply document LESS I believe
> > that would also suit my needs.
> 
> I'd revert it, however Martin said earlier that he loved your change,
> and Andreas was happy enough with it to apply it. So unless Martin
> and/or Andreas changed their mind and tell me I can revert it, I'll just
> leave it as is. I don't want to go against the majority ;-)

Oops, I didn't want to block things here. I found the patch
interesting at the first glance, but your later discussion convinced
me otherwise (yeah, I'm quite easy to convince).

feel free to revert.
Mt

-- 
I am convinced that this paper does not met the usual quality standard,
but I still recommand its acceptation since I'm marked as a co-author.
Sorry.   -- Bastard Professor From Hell

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] scripts: let users override LESS env variable.

2013-12-14 Thread Martin Quinson
On Sat, Dec 14, 2013 at 02:28:49PM +0100, Jean Delvare wrote:
> Hi Kent,
> 
> Le Friday 13 December 2013 à 22:01 -0600, Kent R. Spillner a écrit :
> > Add a QUILT_LESS_ARGS variable that can be used to configure what quilt will
> > set LESS to when LESS is undefined.  Defaults to -FSRX so no functional 
> > change
> > in the default case, but allows users to drop the -F argument as needed (for
> > example, when using a multiline shell prompt) without explicitly setting 
> > LESS.
> 
> I do not understand the value of this change. How is it better to set
> QUILT_LESS_ARGS in ~/.quiltrc than to set LESS in ~/.quiltrc?

Consistency with the other QUILT_*_ARGS maybe?

> As far as I can see, the feature was already there, just not documented.
> If I'm missing something, please explain.

I love interface consistency myself too. I like this change.

Bye, Mt.

-- 
The only merit of this paper is to demonstrate all what you have to
not do when writing an article.  -- Bastard Reviewer From Hell

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] Quilt 0.61 released

2013-12-08 Thread Martin Quinson
Hello,

it was almost 2 years that we didn't release quilt, so I just bumped
the version number and uploaded the new archive.  Since v0.60, we did
not introduce any major feature, but quite a bunch of bugs got fixed,
and some vendor-specific patches got merged (see quilt.changes for
details).

Please enjoy this new version,
Mt.

-- 
You have a problem and you decide to use UTF8. 
Now you have <30> problems.  -- Old Computer Engineers saying

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Quilt 0.61 is coming

2013-09-05 Thread Martin Quinson
Hello,

were do we stand with regard to releasing quilt? This message is now
10 months old, and I feel that not much happened in between. I've sent
a bunch of the debian patches on the list, some of them got refused
(and I'll have to refurbish them), some not. 

I did not commit the patches that were not commented. I'm speaking
of patches 3 to 5 of my previous batch in december-january. Should I
do so? Should we release as is and discuss further integration of the
differing patch sets in each distribution?

I fear that quilt is slowly diverging, as I just uploaded the 10th
version of the 0.60 package in Debian, loaded with 17 patches...

Bye, Mt.

On Wed, Dec 19, 2012 at 10:31:01AM +0100, Jean Delvare wrote:
> Hi all,
> 
> We have committed 44 changes since quilt 0.60 was released. Some are
> fixing bugs which were annoying users in the real world. There are also
> significant improvements to the setup command as well as to emacs
> integration. I think this is enough to warrant scheduling the release of
> quilt 0.61.
> 
> I won't have the time to do that before I leave for vacation, but I
> propose to schedule a release for mid-January, 2013. This should give
> anyone some time for testing and reporting if anything doesn't look
> right (positive feedback is welcome too, of course.)
> 
> I know there are a few issues pending still, but nothing blocking as far
> as I can see. If there is any known critical bug remaining, please let
> me know.
> 
> Debian maintainers, if you have one or two easy patches you'd like to
> upstream in this release, now is the time to submit them.
> 
> Thanks,
> -- 
> Jean Delvare
> Suse L3
> 
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
I can't believe the authors took the time to present, analyze and
prove an algorithm for this middle-school problem.
 -- Bastard Reviewer From Hell

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] test suite: Record the status returned by every command

2013-06-18 Thread Martin Quinson
I must confess that I cannot remember why I needed this, actually.
Beside of this, I have nothing against the feature. Throughfully
reviewing the patch would need more time than what I can devote, but I
trust you.

Mt

On Fri, May 31, 2013 at 02:43:10PM +0200, Jean Delvare wrote:
> Record the status returned by every command, so that test cases can
> check them.
> ---
> Andreas, what do you think? Martin had a use case for this some months
> ago.
> 
>  test/run |   36 ++--
>  1 file changed, 22 insertions(+), 14 deletions(-)
> 
> --- a/test/run
> +++ b/test/run
> @@ -81,6 +81,7 @@ if (defined $ARGV[0]) {
>  }
>  
>  for (;;) {
> +  my $last_status;
>my $line = ; $lineno++;
>if (defined $line) {
>  # Substitute %{VAR} with environment variables.
> @@ -92,13 +93,16 @@ for (;;) {
>  } elsif ($line =~ s/^\s*> ?//) {
>push @$out, $line;
>  } else {
> -  process_test($prog, $prog_line, $in, $out);
> +  $last_status = process_test($prog, $prog_line, $in, $out);
>last if $prog_line >= $opt_l;
>  
>$prog = [];
>$prog_line = 0;
>  }
>  if ($line =~ s/^\s*\$ ?//) {
> +  # Substitute %{?} with the last command's status.
> +  $line =~ s[%{\?}][$last_status]eg;
> +
>$prog = [ map { s/\\(.)/$1/g; $_ } split /(?$prog_line = $lineno;
>$in = [];
> @@ -132,13 +136,14 @@ exit $failed ? 1 : 0;
>  
>  sub process_test() {
>my ($prog, $prog_line, $in, $out) = @_;
> +  my ($result, $exec_status);
>  
>return unless @$prog;
>  
> my $p = [ @$prog ];
> print_body "[$prog_line] \$ ".join(' ',
>map { s/\s/\\$&/g; $_ } @$p)." -- ";
> -   my $result = exec_test($prog, $in);
> +   ($exec_status, $result) = exec_test($prog, $in);
> my @good = ();
> my $nmax = (@$out > @$result) ? @$out : @$result;
> for (my $n=0; $n < $nmax; $n++) {
> @@ -171,6 +176,8 @@ sub process_test() {
> $r, $good[$n], $l);
>   }
> }
> +
> +   return $exec_status;
>  }
>  
>  
> @@ -180,7 +187,7 @@ sub su($) {
>$user ||= "root";
>  
>my ($login, $pass, $uid, $gid) = getpwnam($user)
> -or return [ "su: user $user does not exist\n" ];
> +or return 1, [ "su: user $user does not exist\n" ];
>my @groups = ();
>my $fh = new FileHandle("/etc/group")
>  or return [ "opening /etc/group: $!\n" ];
> @@ -201,17 +208,17 @@ sub su($) {
>$( = $gid;
>$) = $groups;
>if ($!) {
> -return [ "su: $!\n" ];
> +return 1, [ "su: $!\n" ];
>}
>if ($uid != 0) {
>  $> = $uid;
>  #$< = $uid;
>  if ($!) {
> -  return [ "su: $prog->[1]: $!\n" ];
> +  return 1, [ "su: $prog->[1]: $!\n" ];
>  }
>}
>#print STDERR "[($>,$<)($(,$))]";
> -  return [];
> +  return 0, [];
>  }
>  
>  
> @@ -237,10 +244,10 @@ sub sg($) {
> $) = $groups;
>}
>if ($!) {
> -return [ "sg: $!\n" ];
> +return 1, [ "sg: $!\n" ];
>}
>print STDERR "[($>,$<)($(,$))]";
> -  return [];
> +  return 0, [];
>  }
>  
>  
> @@ -251,13 +258,13 @@ sub exec_test($$) {
>  
>if ($prog->[0] eq "umask") {
>  umask oct $prog->[1];
> -return [];
> +return 0, [];
>} elsif ($prog->[0] eq "cd") {
>  if (!chdir $prog->[1]) {
> -  return [ "chdir: $prog->[1]: $!\n" ];
> +  return 1, [ "chdir: $prog->[1]: $!\n" ];
>  }
>  $ENV{PWD} = getcwd;
> -return [];
> +return 0, [];
>} elsif ($prog->[0] eq "su") {
>  return su($prog->[1]);
>} elsif ($prog->[0] eq "sg") {
> @@ -267,10 +274,10 @@ sub exec_test($$) {
>  # FIXME: need to evaluate $value, so that things like this will work:
>  # export dir=$PWD/dir
>  $ENV{$name} = $value;
> -return [];
> +return 0, [];
>} elsif ($prog->[0] eq "unset") {
>  delete $ENV{$prog->[1]};
> -return [];
> +return 0, [];
>}
>  
>pipe *IN2, *OUT
> @@ -320,7 +327,8 @@ sub exec_test($$) {
>}
>push @$result, $_;
>  }
> -return $result;
> +wait();
> +return $? >> 8, $result;
>} else {
>  # Client
>  $< = $>;
> 
> -- 
> Jean Delvare
> Suse L3
> 

-- 
The day Microsoft makes something that doesn't suck is probably the
day they start making vacuum cleaners.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] Makefile.in: Fix "find -perm" usage

2013-05-21 Thread Martin Quinson
Do you have any information on the portability of this new syntax? In
praticular, since when is it in GNU findutils, and what's the support
of this syntax on non-GNU systems? BSD ones come to mind.

Thanks for your time, Mt

On Tue, May 21, 2013 at 10:16:02PM +0400, Dmitry V. Levin wrote:
> Support for obsolete find -perm +MODE syntax
> was removed from GNU findutils by commit
> v4.5.10-144-g90f0c5d24153ad3327edd6f2249fc95a5cfb72e0.
> ---
>  Makefile.in | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/Makefile.in b/Makefile.in
> index cdb5351..4650fda 100644
> --- a/Makefile.in
> +++ b/Makefile.in
> @@ -274,7 +274,7 @@ Makefile : Makefile.in configure
>   @echo "Please run ./configure"
>   @false
>  
> -compat_leftover := $(filter-out $(COMPAT),$(shell $(FIND) compat -maxdepth 1 
> -type f -perm +111))
> +compat_leftover := $(filter-out $(COMPAT),$(shell $(FIND) compat -maxdepth 1 
> -type f -perm /111))
>  
>  .PHONY :: compat
>  compat :: $(COMPAT)
> 
> -- 
> ldv
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
Ce que nous vendons à Coca-Cola, c'est du temps de cerveau humain disponible. 
 -- Patrick Le Lay, PDG de TF1 (L'Expansion, 09/07/2004).

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH 2/2] quilt patches: Add support for multiple files

2013-05-21 Thread Martin Quinson
I did not really test your code, but I read it and it seems very
reasonnable to me. You should commit it I guess.

Thanks for your time,
Mt

On Tue, Apr 30, 2013 at 02:36:59PM +0200, Jean Delvare wrote:
> Add support for multiple files to "quilt patches". Patches will be
> printed, that modify any of the listed files.
> ---
>  quilt/patches.in |   67 
> ---
>  1 file changed, 45 insertions(+), 22 deletions(-)
> 
> --- a/quilt/patches.in
> +++ b/quilt/patches.in
> @@ -17,13 +17,15 @@ then
>   . $QUILT_DIR/scripts/patchfns
>  fi
>  
> +declare -a opt_files=()
> +
>  usage()
>  {
> - printf $"Usage: quilt patches [-v] {file}\n"
> + printf $"Usage: quilt patches [-v] {file} [files...]\n"
>   if [ x$1 = x-h ]
>   then
>   printf $"
> -Print the list of patches that modify the specified file. (Uses a
> +Print the list of patches that modify any of the specified files. (Uses a
>  heuristic to determine which files are modified by unapplied patches.
>  Note that this heuristic is much slower than scanning applied patches.)
>  
> @@ -38,18 +40,26 @@ Note that this heuristic is much slower
>   fi
>  }
>  
> +# Uses global variable opt_files
>  scan_applied()
>  {
> - local color=$1 prefix=$2 file=$3
> - shift 3
> - local patch
> + local color=$1 prefix=$2
> + shift 2
> + local patch file match
>  
>   for patch in "$@"
>   do
> - if [ -f "$(backup_file_name $patch "$file")" ]
> - then
> - echo "$color$prefix$(print_patch $patch)$color_clear"
> - fi
> + match=
> + for file in "${opt_files[@]}"
> + do
> + if [ -f "$(backup_file_name $patch "$file")" ]
> + then
> + match=1
> + break
> + fi
> + done
> +
> + [ -z "$match" ] || echo "$color$prefix$(print_patch 
> $patch)$color_clear"
>   done
>  }
>  
> @@ -74,22 +84,31 @@ touched_by_patch()
>   }'
>  }
>  
> +# Uses global variable opt_files
>  scan_unapplied()
>  {
> - local color=$1 prefix=$2 file=$3 strip
> - shift 3
> - local file_bre="$(quote_bre $file)" patch
> + local color=$1 prefix=$2 strip
> + shift 2
> + local patch file file_bre match
>  
>   for patch in "$@"
>   do
>   strip=$(patch_strip_level $patch)
>   [ "$strip" = ab ] && strip=1
>  
> - if touched_by_patch $strip $patch \
> -| grep -q "^$file_bre\$"
> - then
> - echo "$color$prefix$(print_patch $patch)$color_clear"
> - fi
> + match=
> + for file in "${opt_files[@]}"
> + do
> + file_bre="$(quote_bre "$file")"
> + if touched_by_patch $strip $patch \
> +| grep -q "^$file_bre\$"
> + then
> + match=1
> + break
> + fi
> + done
> +
> + [ -z "$match" ] || echo "$color$prefix$(print_patch 
> $patch)$color_clear"
>   done
>  }
>  
> @@ -129,11 +148,15 @@ do
>   esac
>  done
>  
> -if [ $# -ne 1 ]
> +if [ $# -lt 1 ]
>  then
>   usage
>  fi
> -opt_file="$SUBDIR$1"
> +while [ $# -ge 1 ]
> +do
> + opt_files[${#opt_files[@]}]="$SUBDIR$1"
> + shift
> +done
>  
>  top=$(top_patch)
>  
> @@ -152,12 +175,12 @@ fi
>  
>  setup_pager
>  
> -scan_applied "$color_series_app" "$applied" "$opt_file" \
> +scan_applied "$color_series_app" "$applied" \
>   $(patches_before $top)
>  [ -n "$top" ] && \
> - scan_applied "$color_series_top" "$current" "$opt_file" \
> + scan_applied "$color_series_top" "$current" \
>   $top
> -scan_unapplied "$color_series_una" "$unapplied" "$opt_file" \
> +scan_unapplied "$color_series_una" "$unapplied" \
>   $(patches_after $top)
>  
>  ### Local Variables:
> 
> -- 
> Jean Delvare
> Suse L3
> 
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
Le soir, on regarde la télévision, puisque s'aimer, c'est regarder dans la
même direction.   -- Les malpolis

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH 1/2] quilt patches: Fix shift in scan_unapplied

2013-05-21 Thread Martin Quinson
This seems obvious enough to get commited. 

Thanks for your time, 
Mt

On Tue, Apr 30, 2013 at 02:35:16PM +0200, Jean Delvare wrote:
> Commit 2e581933 added a parameter to function scan_unapplied but the
> corresponding shift wasn't adjusted accordingly. Apparently this bug
> was harmless but there is a slight performance penalty so let's fix
> it still.
> ---
>  quilt/patches.in |2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- a/quilt/patches.in
> +++ b/quilt/patches.in
> @@ -77,7 +77,7 @@ touched_by_patch()
>  scan_unapplied()
>  {
>   local color=$1 prefix=$2 file=$3 strip
> - shift 2
> + shift 3
>   local file_bre="$(quote_bre $file)" patch
>  
>   for patch in "$@"
> 
> -- 
> Jean Delvare
> Suse L3
> 
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
Ceterum censeo Applem delendam esse.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] Fix ugly test-breaking spam with Perl 5.16+ and Locale::gettext

2013-04-01 Thread Martin Quinson
On Sun, Mar 31, 2013 at 07:56:56PM +0100, Nix wrote:
> Perl 5.16+ has started to complain if you import all symbols from both
> POSIX and Locale::gettext, which quilt does in a couple of places. 

Many thanks for the feedback. I wasn't aware of it.

> Index: quilt/quilt/scripts/edmail.in
> ===
> --- quilt.orig/quilt/scripts/edmail.in2013-03-31 19:37:11.190159678 
> +0100
> +++ quilt/quilt/scripts/edmail.in 2013-03-31 19:37:13.129997757 +0100
> @@ -7,6 +7,7 @@
>  #Message Header Extensions for Non-ASCII Text
>  
>  use Getopt::Long;
> +use POSIX qw(setlocale);
>  use strict;
>  
>  # This ugly trick lets the script work even if gettext support is missing.
> @@ -15,8 +16,6 @@
>  BEGIN {
>  if (eval { require Locale::gettext }) {
>   import Locale::gettext;
> - require POSIX;
> - import POSIX, qw(setlocale);
>  } else {
>   eval '
>   use constant LC_MESSAGES => 0;

My concern with your patch is that it makes quilt depending on POSIX
in every case. How will it work on windows minsys or mingw, for
example?

The initial intend of the code was to use the locales if available,
and keep working (using english messages) if not.

Is it possible to do something like "use POSIX qw(setlocale) || true;"
(or similar) so that it works when this package is not available?

Thanks for raising the issue and the initial patch anyway,
Mt

-- 
Si vous pensez que la technologie peut résoudre vos problèmes de
sécurité alors vous n'avez rien compris aux problèmes ni à la
technologie.  -- Bruce Schneier

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] 32093 - QUILT_COLORS

2013-02-04 Thread Martin Quinson
On Mon, Feb 04, 2013 at 09:25:24AM +0100, Daniel Lovasko wrote:
> Hi, 
> 
> I worked on the issues you mentioned, what do you think about this revision?

This is much better, thanks. You could maybe add a link from the
--color documentation in the commands and this new section you added.
Also, what about adding an example? Here is a start that you need to
rewrite a bit to better integrate it to your flow:

> After that, you can say that the content of QUILT_COLORS is simply
> used to superseed default values. So if I set
> QUILT_COLORS='diff_hdr=35;44', I'll get my diff headers in magenta
> over blue instead of the default green with background unchanged.

And finally, I'd say that the info available on
http://tldp.org/LDP/abs/html/colorizing.html#AEN20229 are small enough
to inline these information in the manpage.

Finally, I still don't know how to activate the coloring by default in
quilt. Do people add --color on each and every command? That'd be
surprising. But I cant tell myself, actually.

Bye, Mt.

-- 
Dans un pays d'extrême droite, tu dis pas non a tout bout de champ, ou alors
au bout du champ de tir. -- Frères misère

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [patch 1/5] Verbosly fail when trying to push a non existant patch

2013-01-25 Thread Martin Quinson
Agreed, this fix is a bit odd, actually. But I have absolutely no time
to devote to quilt within the next month(es). If you don't like the
change, don't integrate it that's fine. 

I marked the URL of your rejection arguments in the metadata of the
patch, and I'll think of how to improve (or drop it in debian too)
during the next round of discussion for patch inclusion.

Please don't delay the release of the next version because of me.

Bye, Mt.

On Wed, Jan 23, 2013 at 11:32:13AM +0100, Jean Delvare wrote:
> Hi Martin,
> 
> Le vendredi 18 janvier 2013 à 15:48 +0100, Martin Quinson a écrit :
> > On Thu, Jan 17, 2013 at 10:53:42AM +0100, Jean Delvare wrote:
> > > This doesn't apply clealy on top of the repository, please rebase.
> > 
> > See in attachment. 
> 
> Thanks.
> 
> I don't like it. It changes the behavior of a corner case in a
> discussable and inconsistent way, plus the implementation adds
> confusion. It can be seen in the test case you contributed:
> 
>   $ quilt push -qa
>   > Patch patches/missing1.diff does not exist
>   > Applying patch patches/missing1.diff
> 
> You made the command fail, yet it still claims that the patch was
> applied, which it was not. So at the very least the check for patch
> existence should be made upfront, _before_ printing "Applying patch %s
> \n".
> 
> Even then, the behavior change can be discussed. The original bug
> reporter and patch contributor claims that a missing patch "usually
> indicates there is a problem". However the fact is that quilt itself
> will let you create this situation. See:
> 
> $ quilt new empty
> Patch empty is now on top
> $ quilt pop
> Patch empty appears to be empty, removing
> 
> No patches applied
> $ quilt push
> Applying patch empty
> Patch empty does not exist; applied empty patch
> 
> Now at patch empty
> $
> 
> This did not involve any manual editing of the series file. As long as
> "quilt pop" lets you pop a missing patch file, I see no rationale for
> "quilt push" failing on missing patch file. The current behavior seems
> reasonable to me (although the wording could be improved, missing !=
> empty) and more importantly, it is consistent. The messages are clear
> enough so the user should notice if the patch wasn't expected to be
> missing/empty. The only problem is in automated context where no human
> can read the message, maybe this is what you (or Nicolas) were worried
> about.
> 
> I am fine changing the behavior if you think it would be helpful in
> practice, but only if this is done in a consistent way. This means that
> "quilt pop" should fail on empty patches if "quilt refresh" wasn't
> called to at least create an empty patch file. In other words, empty
> patches should be handled with success and missing patches should not
> (unless forced.)
> 
> What do you think?
> 
> -- 
> Jean Delvare
> Suse L3
> 

-- 
> Tu connais les cartes mères Gigabyte ?
Ces gens qui croient que quand on est informaticien, on connait tout sur les
pièces détachées. Je suis pas mécanicien moi, je suis pilote.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] 32093 - QUILT_COLORS

2013-01-21 Thread Martin Quinson
On Mon, Jan 21, 2013 at 10:56:35AM +0100, Daniel Lovasko wrote:
> Hi all,
> 
> my solution for this bug: https://savannah.nongnu.org/bugs/?32093 is included 
> in the attachment.
> What do you think?

> +\item[\textsf{QUILT\_COLORS}]
> +By default, quilt uses its predefined color set in order to be more 
> +comprehensible when distiguishing various types of patches, eg. 
> +applied/unapplied, failed, etc. Setting this variable enables overriding 
> +values of certain subset of used colors.

I would say that this is very interesting: I did not know of this
coloring feature: the commands series and patch did not document their
--color parameter, while push was very terse on the meaning of the
parameter argument. I just fixed that, thanks for pointing me on it.

But unfortunately, after reading this new documentation, I was very
far from being able to use this feature. I had to dig into the code
and googling around.

I think that you need to say explicitely that the default setting is:
diff_hdr=32:diff_add=36:diff_mod=35:diff_rem=35:diff_hunk=33:diff_ctx=35:diff_cctx=33:patch_offs=33:patch_fuzz=35:patch_fail=31:patch_applied=32:series_app=32:series_top=33:series_una=00:clear=00

with a word on the syntax. It's a colon (:) separated list of
elements, each being of the form 
  =[;]

It would be interesting to document the whole list of format names
since some are trivially understood (such as diff_hdr) but some other
are less obvious (such as diff_cctx but that may be just me). This may
be part of the command's documentation (in their usage function), as
I don't see reused color names between commands at the first glance.

You also want to specify that the color code is following the
classical bash color escaping, with information retrieved from eg,
http://tldp.org/LDP/abs/html/colorizing.html#AEN20229

After that, you can say that the content of QUILT_COLORS is simply
used to superseed default values. So if I set
QUILT_COLORS='diff_hdr=35;44', I'll get my diff headers in magenta
over blue instead of the default green with background unchanged.

Well, I fear that it takes a full documentation section to explain it
all, actually.

Thanks for your time,
Mt.


-- 
Dans la france profonde, il y a surtout des spéléologues.
   -- Le Chat

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] 27111 - bash completion

2013-01-20 Thread Martin Quinson
Hello Daniel,

well, I dunno. My feeling is that firering a perl process each time we
press on tab is somehow wrong. But I now realize that quilt already
depends on perl on several locations. That looks wrong to me but if
the others don't mind, I guess that your patch can get in as it is.

Thanks for your time,
Mt

On Sun, Jan 20, 2013 at 01:15:47AM +0100, Daniel Lovasko wrote:
> Hi Martin!
> 
> The only reason for choosing perl over sed, was perl's regex ability \Q \E, 
> which stops regex engine from interpreting
> text between them (something like literal mode) - resulting into fact, that 
> variable $QUILT_PATCHES can be freely pasted
> into the regex. So that there is no worry having special meta-characters 
> inside the variable. 
> 
> While I do not see your point (but I still respect it), I can offer this 
> sed-only solution:
> before passing the $QUILT_PATCHES, make a copy of it, and in that copy, 
> substitute all special meta-chars that sed
> recognizes with their literal alternative. For example changing "." into "\.".
> 
> What do you think? Should I implement this?
> Thanks for your feedback and have a nice day,
> 
> Daniel
> 
> >>> Martin Quinson  01/19/13 11:00 AM >>>
> Hello Daniel, thanks for your work.
> 
> On Thu, Jan 17, 2013 at 02:50:08PM +0100, Daniel Lovasko wrote:
> > Hi all,
> > 
> > in the attached patch is my solution for this bug.
> 
> Could you please comment a bit on how different this solution is wrt
> the patch gentoo278641b.patch provided by the bug reporter? From what
> I can see, you went for perl instead of sed and adapted to the fact
> that errors are redirected to /dev/null.
> 
> I'd say that relying on perl is wrong. If we mandate perl anywhere in
> quilt, we should rather reimplement anything in perl. Could you please
> change it back to sed?
> 
> Thanks again, Mt.
> 
> PS: I was wondering whether it is possible to write some sort of test
> files for this, but I guess it's simply impossible.
> 
> > diff --git a/bash_completion b/bash_completion
> > index 19736cb..1241d15 100644
> > --- a/bash_completion
> > +++ b/bash_completion
> > @@ -86,6 +86,21 @@ _quilt_comfile()
> >  done
> >  }
> >  
> > +# Resolve paths to patches only inside QUILT_PATCHES directory
> > +# 
> > +# Problem with `quilt series` within completion is it's nature of output
> > +#  as it produces relative path to current working directory, instead of 
> > +#  relative path to QUILT_PATCHES directory.
> > +#
> > +# sed explanation: capture as many as possible of "../" and after that
> > +#  QUILT_PATCHES directory name (if not defined, use default "patches")
> > +#  and remove it all from each filename
> > +#
> > +_quilt_patchlist()
> > +{
> > +quilt $1 | perl -pne 's:^(\.\./)*\Q'"${QUILT_PATCHES:-patches}"'\E/?::'
> > +}
> > +
> >  _quilt_completion()
> >  {
> >  local cur prev cmds command_matches
> > @@ -123,7 +138,7 @@ _quilt_completion()
> >  add)
> > case $prev in
> >   -P)
> > - COMPREPLY=( $( compgen -W "$(quilt applied 2>/dev/null)" -- 
> > $cur ) )
> > + COMPREPLY=( $( compgen -W "$(_quilt_patchlist applied 
> > 2>/dev/null)" -- $cur ) )
> >  ;;
> >   *)
> >  _quilt_comfile
> > @@ -134,7 +149,7 @@ _quilt_completion()
> >  annotate)
> > case $prev in
> >   -P)
> > - COMPREPLY=( $( compgen -W "$(quilt applied 2>/dev/null)" -- 
> > $cur ) )
> > + COMPREPLY=( $( compgen -W "$(_quilt_patchlist applied 
> > 2>/dev/null)" -- $cur ) )
> >  ;;
> >   *)
> >  _quilt_comfile
> > @@ -143,10 +158,10 @@ _quilt_completion()
> > esac
> > ;;
> >  applied) 
> > -   COMPREPLY=( $( compgen -W "-h $(quilt applied 2>/dev/null)" -- $cur 
> > ) )
> > +   COMPREPLY=( $( compgen -W "-h $(_quilt_patchlist applied 
> > 2>/dev/null)" -- $cur ) )
> > ;;
> >  delete) 
> > -   COMPREPLY=( $( compgen -W "-n -r -h --backup $(quilt series)" -- 
> > $cur ) )
> > +   COMPREPLY=( $( compgen -W "-n -r -h --backup $(_quilt_patchlist 
> > series)" -- $cur ) )
> > ;;
> >  diff) 
> > case $prev in
> > @@ -154,7 +169,7 @@ _quilt_completion()
> >   COMPREPLY=( $(

Re: [Quilt-dev] [patch 2/5] Return 2 (instead of 1) when there is nothing to do

2013-01-19 Thread Martin Quinson
On Fri, Jan 18, 2013 at 09:47:09AM +0100, Jean Delvare wrote:
> Le mercredi 19 décembre 2012 à 15:35 +0100, martin.quin...@loria.fr a
> >  [ -z "$opt_verbose" ] && silent_unless_verbose=-s
> >  [ -n "$opt_force" ] && opt_leave_rejects=1
> > --- a/quilt/scripts/patchfns.in
> > +++ b/quilt/scripts/patchfns.in
> > @@ -477,7 +477,7 @@ find_last_patch()
> > else
> > printf $"No series file found\n" >&2
> > fi
> > -   return 1
> > +   return 2
> > fi
> >  
> > echo "$patch"
> 
> This change doesn't have any effect in practice. The only caller of
> find_last_patch() is "quilt mail" and it overwrites the returned value.

This is currently the only caller of find_last_patch. I personally
find dangerous to leave personnal mines in the source code just
because nobody currently runs on it. 

> Plus this would make find_first_patch and find_last_patch diverge for no
> good reason.

Should we possibly fix find_first_patch, then?
 
> I would love if this patch would also add test cases for all conditions
> which are supposed to return 2. This would not only guarantee that such
> a regression isn't reintroduced later, but this would also ensure that
> the fix itself is complete. Unfortunately the testing script doesn't
> support for this yet, but I'm working on it.

Do you mind integrating this even before the test code is working?

> It would also be great to update the manual page to document these
> cases, as it currently lacks an EXIT STATUS section.

Actually, was part of another patch in Debian, as we have a proper
EXIT STATUS section. I just merged both patches, and the result is in
attachment. I know that the patch to the manpage contains an unrelated
change, but this is only a cosmetic improvement so I don't feel like
providing a proper patch. If it really hurts your feeling, I'll commit
this unrelated change myself once you pushed your changes to the tree.

Bye, Mt.

-- 
Le problème, ce n'est pas l'internet. Le problème, c'est l'insécurité
désastreuse de tous ces ordinateurs reliés à l'internet. Il vaudrait
mieux réécrire Windows que TCP/IP. -- Bruce Schneier
Description: Return 2 (instead of 1) when there is nothing to do
 This is mandatory to differentiate "error" and "everything's done".
 .
 This really ease the scripting around quilt, eg in patchsys-quilt.mk 
 .
 It used to works this way, and was changed upstream in commit 
 188c7dac15a72c437c47664d3162b9f13844fe88 for quilt version 0.43. This
 regression was the result of a code factorization.
 .
 This patch also contains the documentation update, by adding a EXIT
 STATUS to the man page.
Bug-Debian: http://bugs.debian.org/358792 (return 2 on NO-OP)
Bug-Debian: http://bugs.debian.org/587001 (document exit status)
Forwarded: Submitted 2013-01-18
Changelog:
 - 2012-12-19: Submitted upstream
 - 2013-01-18: Upstream asked for changes and documentation
 - 2013-01-18: new version subitted upstream
Last-Update: 2013-01-18


Index: quilt.git/quilt/push.in
===
--- quilt.git.orig/quilt/push.in2013-01-18 15:35:17.571852522 +0100
+++ quilt.git/quilt/push.in 2013-01-18 15:35:17.511851570 +0100
@@ -362,7 +362,7 @@
[ -z "$opt_all" ] && number=1
 fi
 
-stop_at_patch=$(find_unapplied_patch "$stop_at_patch") || exit 1
+stop_at_patch=$(find_unapplied_patch "$stop_at_patch") || exit
 
 [ -z "$opt_verbose" ] && silent_unless_verbose=-s
 [ -n "$opt_force" ] && opt_leave_rejects=1
Index: quilt.git/quilt/scripts/patchfns.in
===
--- quilt.git.orig/quilt/scripts/patchfns.in2013-01-18 15:35:17.571852522 
+0100
+++ quilt.git/quilt/scripts/patchfns.in 2013-01-18 15:35:17.535851949 +0100
@@ -477,7 +477,7 @@
else
printf $"No series file found\n" >&2
fi
-   return 1
+   return 2
fi
 
echo "$patch"
@@ -582,7 +582,7 @@
then
printf $"Patch %s is currently applied\n" \
"$(print_patch $patch)" >&2
-   return 1
+   return 2
fi
echo "$patch"
else
@@ -592,13 +592,13 @@
then
patch_after "$start"
else
-   find_first_patch || return 1
+   find_first_patch || return 2
fi
if [ $? -ne 0 ]
then
printf $"File series fully applied, ends at patch %s\n" 
\
"$(print_patch $start)" >&2
-   return 1
+   return 2
fi
fi
 }
Index: quilt.git/doc/quilt.1.in
===
--- quilt.git.orig/doc/quilt.1.in   2013-01-18 15:35:

Re: [Quilt-dev] [patch 1/5] Verbosly fail when trying to push a non existant patch

2013-01-19 Thread Martin Quinson
On Thu, Jan 17, 2013 at 10:53:42AM +0100, Jean Delvare wrote:
> This doesn't apply clealy on top of the repository, please rebase.

See in attachment. 

Sorry, Mt.

-- 
Les coups et les douleurs, ca se discute pas.
Description: Verbosly fail when trying to push a non existant patch
 Useful if there is a typo in the serie file.
 This can be overriden by providing -f.
Bug-Debian: http://bugs.debian.org/358875
Forwarded: sent 2012-12-19

---
 quilt/push.in |7 +++
 test/missing.test |4 
 2 files changed, 11 insertions(+)

Index: quilt-upstream/quilt/push.in
===
--- quilt-upstream.orig/quilt/push.in   2013-01-18 15:42:15.146731002 +0100
+++ quilt-upstream/quilt/push.in2013-01-18 15:44:31.773007413 +0100
@@ -186,6 +186,13 @@
no_reject_files="-r $tmp"
fi
 
+   if [ ! -e "$patch_file" -a -z "$opt_force" ]
+   then
+   printf $"Patch %s does not exist\n" \
+  "$(print_patch $patch)" >&2
+   return 1
+   fi
+
apply_patch "$patch" "$patch_file"
status=$?
trap "" SIGINT
Index: quilt-upstream/test/missing.test
===
--- quilt-upstream.orig/test/missing.test   2013-01-18 15:42:15.146731002 
+0100
+++ quilt-upstream/test/missing.test2013-01-18 15:44:49.573303734 +0100
@@ -5,6 +5,10 @@
< missing2.diff

$ quilt push -qa
+   > Patch patches/missing1.diff does not exist
+   > Applying patch patches/missing1.diff
+
+   $ quilt push -qaf
> Applying patch patches/missing1.diff
> Patch patches/missing1.diff does not exist; applied empty patch
> Applying patch patches/missing2.diff
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] 27111 - bash completion

2013-01-19 Thread Martin Quinson
Hello Daniel, thanks for your work.

On Thu, Jan 17, 2013 at 02:50:08PM +0100, Daniel Lovasko wrote:
> Hi all,
> 
> in the attached patch is my solution for this bug.

Could you please comment a bit on how different this solution is wrt
the patch gentoo278641b.patch provided by the bug reporter? From what
I can see, you went for perl instead of sed and adapted to the fact
that errors are redirected to /dev/null.

I'd say that relying on perl is wrong. If we mandate perl anywhere in
quilt, we should rather reimplement anything in perl. Could you please
change it back to sed?

Thanks again, Mt.

PS: I was wondering whether it is possible to write some sort of test
files for this, but I guess it's simply impossible.

> diff --git a/bash_completion b/bash_completion
> index 19736cb..1241d15 100644
> --- a/bash_completion
> +++ b/bash_completion
> @@ -86,6 +86,21 @@ _quilt_comfile()
>  done
>  }
>  
> +# Resolve paths to patches only inside QUILT_PATCHES directory
> +# 
> +# Problem with `quilt series` within completion is it's nature of output
> +#  as it produces relative path to current working directory, instead of 
> +#  relative path to QUILT_PATCHES directory.
> +#
> +# sed explanation: capture as many as possible of "../" and after that
> +#  QUILT_PATCHES directory name (if not defined, use default "patches")
> +#  and remove it all from each filename
> +#
> +_quilt_patchlist()
> +{
> + quilt $1 | perl -pne 's:^(\.\./)*\Q'"${QUILT_PATCHES:-patches}"'\E/?::'
> +}
> +
>  _quilt_completion()
>  {
>  local cur prev cmds command_matches
> @@ -123,7 +138,7 @@ _quilt_completion()
>   add)
>  case $prev in
>-P)
> - COMPREPLY=( $( compgen -W "$(quilt applied 2>/dev/null)" -- 
> $cur ) )
> + COMPREPLY=( $( compgen -W "$(_quilt_patchlist applied 
> 2>/dev/null)" -- $cur ) )
>   ;;
>*)
>   _quilt_comfile
> @@ -134,7 +149,7 @@ _quilt_completion()
>   annotate)
>  case $prev in
>-P)
> - COMPREPLY=( $( compgen -W "$(quilt applied 2>/dev/null)" -- 
> $cur ) )
> + COMPREPLY=( $( compgen -W "$(_quilt_patchlist applied 
> 2>/dev/null)" -- $cur ) )
>   ;;
>*)
>   _quilt_comfile
> @@ -143,10 +158,10 @@ _quilt_completion()
>  esac
>  ;;
>   applied) 
> -COMPREPLY=( $( compgen -W "-h $(quilt applied 2>/dev/null)" -- $cur 
> ) )
> +COMPREPLY=( $( compgen -W "-h $(_quilt_patchlist applied 
> 2>/dev/null)" -- $cur ) )
>  ;;
>   delete) 
> -COMPREPLY=( $( compgen -W "-n -r -h --backup $(quilt series)" -- 
> $cur ) )
> +COMPREPLY=( $( compgen -W "-n -r -h --backup $(_quilt_patchlist 
> series)" -- $cur ) )
>  ;;
>   diff) 
>  case $prev in
> @@ -154,7 +169,7 @@ _quilt_completion()
>   COMPREPLY=( $( compgen -W "0 1" -- $cur ) )
>   ;;
>-P|--combine)
> - COMPREPLY=( $( compgen -W "$(quilt applied 2>/dev/null)" -- 
> $cur ) )
> + COMPREPLY=( $( compgen -W "$(_quilt_patchlist applied 
> 2>/dev/null)" -- $cur ) )
>   ;;
>--diff|-U|-C)
>   ;;
> @@ -171,10 +186,10 @@ _quilt_completion()
>   files)
>  case $prev in
>--combine)
> - COMPREPLY=( $( compgen -W "$(quilt applied 2>/dev/null)" -- 
> $cur ) )
> + COMPREPLY=( $( compgen -W "$(_quilt_patchlist applied 
> 2>/dev/null)" -- $cur ) )
>   ;;
>*)
> - COMPREPLY=( $( compgen -W "-a -l -v -h --combine $(quilt 
> applied 2>/dev/null)" -- $cur ) )
> + COMPREPLY=( $( compgen -W "-a -l -v -h --combine 
> $(_quilt_patchlist applied 2>/dev/null)" -- $cur ) )
>   ;;
>  esac
>  ;;
> @@ -198,7 +213,7 @@ _quilt_completion()
>   COMPREPLY=( $( compgen -W "files" -- $cur ) )
>   ;;
>*)
> - COMPREPLY=( $( compgen -W "-T -h --all --reduce --lines 
> --edge-labels $(quilt applied 2>/dev/null)" -- $cur ) )
> + COMPREPLY=( $( compgen -W "-T -h --all --reduce --lines 
> --edge-labels $(_quilt_patchlist applied 2>/dev/null)" -- $cur ) )
>   ;;
>  esac
>  ;;
> @@ -207,7 +222,7 @@ _quilt_completion()
>  COMPREPLY=( ${COMPREPLY[@]:-} $( compgen -W "-h" -- $cur ) )
>  ;;
>   header)
> -COMPREPLY=( $( compgen -W "-a -e -h -r --backup --strip-diffstat 
> --strip-trailing-whitespace $(quilt series)" -- $cur ) )
> +COMPREPLY=( $( compgen -W "-a -e -h -r --backup --strip-diffstat 
> --strip-trailing-whitespace $(_quilt_patchlist series)" -- $cur ) )
>  ;;
>   import)
>  case $prev in
> @@ -229,17 +244,17 @@ _quilt_completion()
>  COMPREPLY=( $( compgen -W "-m --prefix --mbox --send --sender --from 
> --subject --to --cc --bcc" -- $cur ) )
>  ;;
>   next|previous)
> -CO

[Quilt-dev] Old patch toward "quilt commit" that should be integrated

2012-12-27 Thread Martin Quinson
Hello,

It would be very good if the following patch could make its way into
the next release. We have an old bug in Debian asking for this
feature, too.

http://lists.nongnu.org/archive/html/quilt-dev/2009-11/msg00071.html

Thanks for your time,
Mt.

-- 
Every day of my life I am forced to add another name to the list of people 
who piss me off! --- Calvin

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH, RFC] Stop using patch option -E

2012-12-25 Thread Martin Quinson
Hello,

just for the record, we have a bug in debian to remove the -E option
since a long time, so I'm graceful to you for taking care of it. Here
is the url of the discussion:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=333480

Thanks, Mt.

On Wed, Dec 19, 2012 at 10:06:49AM +0100, Jean Delvare wrote:
> Hi Andreas,
> 
> Thanks for the fast reply.
> 
> Le mardi 18 décembre 2012 à 19:06 +0100, Andreas Grünbacher a écrit :
> > Jean,
> > 
> > 2012/12/18 Jean Delvare :
> > > GNU patch version 2.7 and newer deals just fine with empty files,
> > > however our use of option -E breaks this feature. So stop using this
> > > option. Anyway, the manual page says: "Normally this option is
> > > unnecessary" and the test suite passes just fine without it.
> > >
> > > Andreas, can you remember why we were using option -E? I dug the history
> > > but apparently it has been there since the beginning so I couldn't find
> > > an explanation.
> > 
> > when patch is in POSIX mode or the patch format doesn't allow to distinguish
> > empty files from deleted files, patch deletes empty files only if the -E 
> > option
> > is given. If the -E option is given, patch always deletes empty files.
> > 
> > So if you want to use the -E option or not depends on which kinds of patches
> > you use: with "modern" unified or context diffs as generated by GNU diff or 
> > git,
> > you usually don't want -E; with other patch formats, you usually do want -E.
> > 
> > So I think your change makes sense; if people want -E, they can put it in
> > $QUILT_PATCH_OPTS.
> 
> That was exactly my thought. It's easier to add an option you want to
> $QUILT_PATCH_OPTS than to remove one that was hard-coded into quilt.
> 
> > > I suppose it may help get files deleted when using
> > > QUILT_NO_DIFF_TIMESTAMPS? But OTOH I would hope that GNU patch notices
> > > when the file name is /dev/null and acts appropriately.
> > 
> > Yes it does; the timestamps are not needed for that.
> 
> Thanks for the confirmation, the patch manual page did not make it
> completely clear. I'll do some more tests and if everything looks
> correct I'll just commit this change, with additional documentation.
> 
> -- 
> Jean Delvare
> Suse L3
> 
> 
> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev

-- 
Alvin: Sinon, le polymorphisme en C, c'est trop bô. :)
Emptty: Ca, c'est clair. Le C, j'aime ca. C'est un peu de l'art primitif,
   mais ca te secoue les tripes...

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] Fwd: Re: [PATCH, RFC] Stop using patch option -E

2012-12-25 Thread Martin Quinson
It seems that this mail never went through, so I'm resending it. Jean,
you said that you wanted to add some documentation, so you may want to
use it as a base.

Bye, Mt.

- Forwarded message from Martin Quinson  -

Date: Tue, 18 Dec 2012 21:48:34 +0100
From: Martin Quinson 
To: quilt-dev@nongnu.org
Subject: Re: [Quilt-dev] [PATCH, RFC] Stop using patch option -E
User-Agent: Mutt/1.5.21 (2010-09-15)

On Tue, Dec 18, 2012 at 07:06:25PM +0100, Andreas Grünbacher wrote:
> Jean,
> 
> 2012/12/18 Jean Delvare :
> > GNU patch version 2.7 and newer deals just fine with empty files,
> > however our use of option -E breaks this feature. So stop using this
> > option. Anyway, the manual page says: "Normally this option is
> > unnecessary" and the test suite passes just fine without it.
> >
> > Andreas, can you remember why we were using option -E? I dug the history
> > but apparently it has been there since the beginning so I couldn't find
> > an explanation.
> 
> when patch is in POSIX mode or the patch format doesn't allow to distinguish
> empty files from deleted files, patch deletes empty files only if the -E 
> option
> is given. If the -E option is given, patch always deletes empty files.
> 
> So if you want to use the -E option or not depends on which kinds of patches
> you use: with "modern" unified or context diffs as generated by GNU diff or 
> git,
> you usually don't want -E; with other patch formats, you usually do want -E.
> 
> So I think your change makes sense; if people want -E, they can put it in
> $QUILT_PATCH_OPTS.

You may want to add the following patch, then. 

Thanks for your time, both of you.
Mt

diff --git a/doc/quilt.1.in b/doc/quilt.1.in
index db91b14..8cb0106 100644
--- a/doc/quilt.1.in
+++ b/doc/quilt.1.in
@@ -164,7 +164,19 @@ Additional options that quilt shall pass to GNU patch when 
applying
 patches.  For example, recent versions of GNU patch support the
 "--reject-format=unified" option for generating reject files in unified
 diff style (older patch versions used "--unified-reject-files" for that).
-
+
+You may also want to add the "-E" option if you are experiencing
+issues having quilt to delete empty files. The documentation of GNU
+patch says that "normally this option is unnecessary", but when patch
+is in POSIX mode or if the patch format doesn't allow to distinguish
+empty files from deleted files, patch deletes empty files only if the
+-E option is given. 
+
+So whether or not adding the -E option actually depends on which kinds
+of patches is used: with "modern" unified or context diffs as
+generated by GNU diff or git, you usually don't want -E; with other
+patch formats, you usually do want -E.
+
 .IP QUILT_DIFFSTAT_OPTS 4
 
 Additional options that quilt shall pass to diffstat when generating

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 5/5] Implement a new "quilt shell" command

2012-12-19 Thread martin . quinson
Description: Implement a new "quilt shell" command
 The command launches a shell in a duplicate environment. After exiting
 the shell, any modifications made in this environment are applied to the
 topmost patch.
Author: Josselin Mouette 
Bug-Debian: http://bugs.debian.org/526141
Forwarded: submitted 2012-12-19

---
 quilt/shell.in |   67 +
 1 file changed, 67 insertions(+)

--- /dev/null
+++ b/quilt/shell.in
@@ -0,0 +1,67 @@
+#! @BASH@
+
+#  This script is free software; you can redistribute it and/or modify
+#  it under the terms of the GNU General Public License version 2 as
+#  published by the Free Software Foundation.
+#
+#  See the COPYING and AUTHORS files for more details.
+
+# Read in library functions
+if [ "$(type -t patch_file_name)" != function ]
+then
+if ! [ -r $QUILT_DIR/scripts/patchfns ]
+then
+echo "Cannot read library $QUILT_DIR/scripts/patchfns" >&2
+exit 1
+fi
+. $QUILT_DIR/scripts/patchfns
+fi
+
+if [ "$1" = "-h" ]; then
+printf $"Usage: quilt shell [command]\n"
+printf $"
+Launch a shell in a duplicate environment. After exiting the shell, any
+modifications made in this environment are applied to the topmost patch.
+
+If a command is specified, it is executed instead of launching the shell.
+"
+exit 0
+fi
+
+tmpdir=$(mktemp -d /tmp/quilt-XX)
+
+cp -a . $tmpdir
+
+(
+cd $tmpdir/"$SUBDIR"
+if [ $# -gt 0 ]; then
+exec "$@"
+else
+$SHELL
+fi
+)
+
+# Find new directories
+( cd $tmpdir; find . -type d ! -path ./"$QUILT_PC"/\* ! -path 
./"$QUILT_PATCHES"/\* ) | while read dir; do
+if [ ! -d "$dir" ]; then
+mkdir -p "$dir"
+fi
+done
+
+# New and modified files
+( cd $tmpdir; find . -type f ! -path ./"$QUILT_PC"/\* ! -path 
./"$QUILT_PATCHES"/\* ) | while read file; do
+if [ ! -f "$file" ] || ! diff -q "$file" $tmpdir/"$file" > /dev/null 2>&1; 
then
+quilt_command add "$file"
+cp -a $tmpdir/"$file" "$file"
+fi
+done
+
+# Removed files
+( find . -type f ! -path ./"$QUILT_PC"/\* ! -path ./"$QUILT_PATCHES"/\* ) | 
while read file; do
+if [ ! -f $tmpdir/"$file" ]; then
+quilt_command add "$file"
+rm -f "$file"
+fi
+done
+
+rm -rf $tmpdir
--- a/bash_completion
+++ b/bash_completion
@@ -97,7 +97,7 @@ _quilt_completion()
 # quilt sub commands 
 cmds='add annotate applied delete diff edit files fold fork graph \
   grep header import mail new next patches pop previous push refresh \
- remove rename revert series setup snapshot top unapplied'
+ remove rename revert series setup shell snapshot top unapplied'
 
 # if no command were given, complete on commands
 if [[ $COMP_CWORD -eq 1 ]] ; then


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 4/5] verbosly die if /proc is not mounted

2012-12-19 Thread martin . quinson
Description: verbosly die if /proc is not mounted
 Let patch-wrapper die with an informative message when /proc is not mounted
 althrough it needs it to pass the patching request to GNU patch since it
 fails to understand all options.
Forwarded: submitted 2012-12-19

--- a/bin/patch-wrapper.in
+++ b/bin/patch-wrapper.in
@@ -171,6 +171,10 @@ then
 if [ -n "$opt_input" ]
 then
patch=$opt_input
+elif [ ! -e /proc/self ]
+then
+echo "patch-wrapper: /proc not mounted!" >&2
+   exit 1
 elif [ -e /proc/self/fd/0 ]
 then
patch=$(readlink /proc/self/fd/0)


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 2/5] Return 2 (instead of 1) when there is nothing to do

2012-12-19 Thread martin . quinson
Description: Return 2 (instead of 1) when there is nothing to do
 This is mandatory to differenciate "error" and "everything's done".
 .
 This really ease the scripting around quilt, eg in patchsys-quilt.mk 
 .
 It used to works this way in quilt 0.33, and was changed for some
 reason upstream.
Bug-Debian: http://bugs.debian.org/358792
Forwarded: Submitted 2012-12-19

---
 quilt/push.in |2 +-
 quilt/scripts/patchfns.in |8 
 2 files changed, 5 insertions(+), 5 deletions(-)

--- a/quilt/push.in
+++ b/quilt/push.in
@@ -362,7 +362,7 @@ else
[ -z "$opt_all" ] && number=1
 fi
 
-stop_at_patch=$(find_unapplied_patch "$stop_at_patch") || exit 1
+stop_at_patch=$(find_unapplied_patch "$stop_at_patch") || exit $?
 
 [ -z "$opt_verbose" ] && silent_unless_verbose=-s
 [ -n "$opt_force" ] && opt_leave_rejects=1
--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -477,7 +477,7 @@ find_last_patch()
else
printf $"No series file found\n" >&2
fi
-   return 1
+   return 2
fi
 
echo "$patch"
@@ -582,7 +582,7 @@ find_unapplied_patch()
then
printf $"Patch %s is currently applied\n" \
"$(print_patch $patch)" >&2
-   return 1
+   return 2
fi
echo "$patch"
else
@@ -592,13 +592,13 @@ find_unapplied_patch()
then
patch_after "$start"
else
-   find_first_patch || return 1
+   find_first_patch || return 2
fi
if [ $? -ne 0 ]
then
printf $"File series fully applied, ends at patch %s\n" 
\
"$(print_patch $start)" >&2
-   return 1
+   return 2
fi
fi
 }


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 3/5] verbose error message when the serie file does not exist

2012-12-19 Thread martin . quinson
Description: verbose error message when the serie file does not exist
 Displays an error message when the $SERIES file does not exist and when run
 in verbose mode.
Bug-Debian: http://bugs.debian.org/369908 
Upstream-status: submitted 2012-12-19

---
 quilt/scripts/patchfns.in |3 +++
 1 file changed, 3 insertions(+)

--- a/quilt/scripts/patchfns.in
+++ b/quilt/scripts/patchfns.in
@@ -323,6 +323,9 @@ cat_series()
sed -e '/^#/d' -e 's/^[ '$'\t'']*//' \
-e 's/[ '$'\t''].*//' -e '/^$/d' $SERIES
else
+   if [ "$opt_verbose" ]; then
+   echo "series file not found: $SERIES" >&2
+   fi
return 1
fi
 }


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 0/5] Some patches from the Debian package

2012-12-19 Thread martin . quinson
Here are a bunch of patches that were laying in the Debian package and
that seem ready for consumption upstream.

Thanks for the reminder,
Mt.


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [patch 1/5] Verbosly fail when trying to push a non existant patch

2012-12-19 Thread martin . quinson
Description: Verbosly fail when trying to push a non existant patch
 Useful if there is a typo in the serie file.
 This can be overriden by providing -f.
Bug-Debian: http://bugs.debian.org/358875
Forwarded: sent 2012-12-19

---
 quilt/push.in |7 +++
 test/missing.test |4 
 2 files changed, 11 insertions(+)

--- a/quilt/push.in
+++ b/quilt/push.in
@@ -184,6 +184,13 @@ add_patch()
no_reject_files="-r $tmp"
fi
 
+   if [ ! -e "$patch_file" -a -z "$opt_force" ]
+   then
+   printf $"Patch %s does not exist\n" \
+  "$(print_patch $patch)" >&2
+   return 1
+   fi
+
apply_patch $patch "$patch_file"
status=$?
trap "" SIGINT
--- a/test/missing.test
+++ b/test/missing.test
@@ -5,6 +5,10 @@
< missing2.diff

$ quilt push -qa
+   > Patch patches/missing1.diff does not exist
+   > Applying patch patches/missing1.diff
+   
+   $ quilt push -qaf
> Applying patch patches/missing1.diff
> Patch patches/missing1.diff does not exist; applied empty patch
> Applying patch patches/missing2.diff


___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] Fix handling of patch files with ':' in their name.

2012-12-02 Thread Martin Quinson
> > -  -a ! -path "$path/.timestamp" |
> > -   sed -e "s:$path/::"
> > +  -a ! -path "$path/.timestamp" \
> > +  -printf "%P\n"
> 
> I can't remember the policy in quilt, but I can't find evidence, that
> -printf is in the POSIX standard yet.

I'm not sure we have an official policy here, but I'd say that we are
pragmatic concerning the portability: we want quilt to be usable on
all platforms that are still used nowadays.

Unless someone objects, I think I'll commit this change; if it breaks
something for an exotic platform at some point, we'll think further:
either revert the change or come up with a better one.

Thanks for your time guys: quilt really needs people to propose
patches and other ones to comment them in order to keep going forward.

Bye, Mt.

-- 
Les chats, c'est vraiment des branleurs.  -- Alain Chabat

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] RFC: improving quilt minor mode for emacs

2012-03-10 Thread Martin Quinson
Hello Satoru,

On Sat, Mar 10, 2012 at 08:17:27PM +0900, satoru takeuchi wrote:
> As I said last week, I merged the following thirteen patches about 
> lib/quilt.el.
> 
> quilt-el: be aware of QUILT_PATCHES
> quilt-el: simplify quilt-revert
> quilt-el: considering default-directory' is nil
> quilt-el: optimize `quilt-revert'
> quilt-el: update the maintainer's email addres.
> quilt-el: return to the original cwd even if `shell-command' failed.
> quilt-el: fix polluting namespace by nested function.
> quilt-el: cleanup codes by introducing `quilt-cmd-to-list' function.
> quilt-el: supporting multiple quilt trees
> quilt-el: make it checkdoc clean.
> quilt-el: make it byte compile clean
> quilt-el: remove `Version' and `URL' tags in the document
> quilt-el: fix `quilt-patch-list' to call `quilt series'..
> 
> Now this script is up-to-date. It would be useful for all emacs&quilt users
> who often accidentally edit not-yet-quilt-added files (yes, It's me.)
> Such mistakes can automatically be avoided by it :-)

Thanks for this work. As an emacs user, I really appreciate ;)

Could you please drop a few words into quilt.changes to summarize the
most important changes?

Thanks again,
Mt.

-- 
This paper needs a major rewrite to fix the English, make it more
concise, explain clearly what exactly is the performance evaluation
methodology, and how it is different from the obvious. 
 -- Bastard Reviewer From Hell (seen for real as PC member)

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] RFC: improving quilt minor mode for emacs

2012-03-03 Thread Martin Quinson
On Sat, Mar 03, 2012 at 11:48:02AM +0900, satoru takeuchi wrote:
> Hi,
> 
> I have about twenty patches for lib/quilt.el, an emacs minor mode for quilt. 
> Can
> I send these patches to this list? These are for improving performance,
> for fixing bugs, and for adding new features. In addition, they are well 
> tested.
> 
> # I send this mail because I hesitate about sending such a big
> patchset abruptly.
> 
> To tell the truth, I once announced the release of quilt-el 0.45.3 [1]
> and it is merged
> to quilt itself (and then I became an quilt committer). However I have updated
> quilt-el separating from quilt itself[2] after that. I don't remember
> why I made such
> ridiculous decision... Anyway, now I would like to re-sync this script
> in quilt and finish
> maintaining it as my own project.
> 
> [1] http://lists.gnu.org/archive/html/quilt-dev/2007-04/msg0.html
> [2] http://satoru-takeuchi.org/dev/quilt-el/index.html

>From my point of view, you could also merge these patches directly
into the quilt repository. After all, you know what you are doing
concerning this minor mode.

In addition, you shouldn't feel sorry about providing a large
patchset: it only mean that you worked a lot for the project ;)

Thanks for that,
Mt.


-- 
If you think that education is expensive, try ignorance.
  -- Albert Einstein

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Quilt 0.51 has been released

2012-01-29 Thread Martin Quinson
On Sun, Jan 29, 2012 at 08:29:05PM +0100, Jean Delvare wrote:
> On Saturday 28 January 2012 10:44:23 pm Josh Boyer wrote:
> > On Sat, Jan 28, 2012 at 11:24 AM, Jean Delvare  
> wrote:
> > > As announced a few days ago, I have released quilt 0.51. It
> > > includes a number of fixes most notably to the setup and mail
> > > commands. The rest is mostly fixes and cleanups to the build
> > > infrastructure itself.
> > 
> > Excellent news.  Thank you very much for leading the way again.
> > 
> > For 0.52 (or 0.60?) are you going to look at committing your
> >  backup-files changes to make quilt purely a noarch package?
> 
> Yes, this is exactly the plan. I don't know which version number I'll 
> give it yet, though I tend to agree that the change is big enough to 
> warrant a version number bump greater than 0.01.

You could make it 0.90, so that we have 10 releases to converge to a
stable 1.0 release, maybe.

Mt.

-- 
Source is provided to this software because we believe users have the right
to know exactly what a program is going to do before they run it.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] 0.50 in Debian + Simple patch for inclusion: Fix manpage generation under dash

2012-01-09 Thread Martin Quinson
On Mon, Jan 09, 2012 at 04:16:46PM +0100, Jean Delvare wrote:
> On Monday 09 January 2012 03:20:21 pm Martin Quinson wrote:
> > On Mon, Jan 09, 2012 at 02:50:12PM +0100, Raphael Hertzog wrote:
> > > That or fix the Makefile so that it uses bash as the interpreter.
> > > As I said in my previous message, I believe that you can do that
> > > by setting "SHELL = bash" in the Makefile.
> 
> Thanks for the hint Raphael, and sorry for not listening last time.
> 
> > So, the fix would be to revert the patch to use bash portability
> >  layer here, and simply force the use of bash, I guess. If nobody
> >  speaks against it, I'll do so tomorrow or so.
> 
> Yes, I agree.

Since all three of us agreed, I commited this.

I'll try to pick a simpler patch from Debian for inclusion next time ;)

Bye, Mt.

-- 
Simplicity does not precede complexity, but follows it.
   -- "Epigrams in Programming", by Alan J. Perlis of Yale University.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] 0.50 in Debian + Simple patch for inclusion: Fix manpage generation under dash

2012-01-09 Thread Martin Quinson
On Mon, Jan 09, 2012 at 02:50:12PM +0100, Raphael Hertzog wrote:
> On Mon, 09 Jan 2012, Jean Delvare wrote:
> > I'd like to make sure I understand your problem so that we can come up 
> > with a solution. You're using dash as your /bin/sh implementation. What 
> > is the reason for this? Is it a performance issue? Or is bash really not 
> > available at build time?
> 
> Performance is the reason, yes.
> 
> bash is always available as /bin/bash.
> 
> > I couldn't come up with an alternative for the shell code above. If you 
> > have bash available (and I believe you do, otherwise configure would 
> > complain) then I think the best option is to move the documentation 
> > generation code out of the Makefile to an external bash script.
> 
> That or fix the Makefile so that it uses bash as the interpreter.
> As I said in my previous message, I believe that you can do that
> by setting "SHELL = bash" in the Makefile.

So, the fix would be to revert the patch to use bash portability layer
here, and simply force the use of bash, I guess. If nobody speaks
against it, I'll do so tomorrow or so.

Bye, Mt.

-- 
Si les grands esprits se rencontrent, les petits esprits, eux, se cognent.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] Managing bugs on savannah

2012-01-02 Thread Martin Quinson
On Sun, Jan 01, 2012 at 09:32:14PM +0100, Andreas Gruenbacher wrote:
> On Sun, 2012-01-01 at 20:51 +0100, Martin Quinson wrote:
> > Hello,
> > 
> > I don't seem to have the credentials to close bugs on savannah. That's
> > a pity because https://savannah.nongnu.org/bugs/?34340 was solved, for
> > example. 
> > 
> > Could someone close that bug, and/or give me the credentials to do so?
> 
> I have changed the permissions.  Could you please see if you can manage
> bugs now?  Thanks!

It works, thanks. I'll triage the bugs that we have.

Mt.

-- 
The used notations are unclear and confusing. Since clear writing
leads to clear thinking, I doubt that the authors really understood
their own article. -- Bastard Reviewer From Hell

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] Managing bugs on savannah

2012-01-01 Thread Martin Quinson
Hello,

I don't seem to have the credentials to close bugs on savannah. That's
a pity because https://savannah.nongnu.org/bugs/?34340 was solved, for
example. 

Could someone close that bug, and/or give me the credentials to do so?

Thanks, Mt.

-- 
The irony is that Bill Gates claims to be making a stable operating system
and Linus Torvalds claims to be trying to take over the world.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] 0.50 in Debian + Simple patch for inclusion: Fix manpage generation under dash

2012-01-01 Thread Martin Quinson
FYI, I just commited this. Other info: 0.50 is now in the testing
version of debian, and thus rather extensively tested by all debian
developers at the very least. So far, no problem to report.

Thanks for your good work, and happy new year.
Mt.

On Fri, Dec 23, 2011 at 04:23:19PM +0100, Martin Quinson wrote:
> Hello,
> 
> Raphaël packaged 0.50 for Debian a few days ago, and so far it all
> goes rather well. Only some glitches against the packaging itself were
> reported, nothing against the code.
> 
> Also, now that we are on par with upstream code, we'd like to reduce a
> bit the amount of patches that we have in the package. For the record,
> our series file contains 16 patches, several of them being rather
> simple. I'm proposing a first one, in attachement. If nobody complains
> in the next few days, I'll commit it myself before proceeding to the
> next patch.
> 
> It may seem like a noisy way of integrating our stuff, but I prefer to
> play safe with quilt. It's heavily used and I feel my technical limits
> here. So, sorry for the noise, but that's how I'll do it. If you
> prefer, the whole patch serie is available here:
> http://git.debian.org/?p=collab-maint/quilt.git
> 
> Thanks, and happy chrismas,
> Mt.
> 
> -- 
> Thou shalt foreswear, renounce, and abjure the vile heresy which claimeth
> that ``All the world's a 386'', and have no commerce with the benighted
> heathens who cling to this barbarous belief, that the days of thy program
> may be long even though the days of thy current machine be short.
>   -- Tenth commandment of the C programmer

> Description: Fix auto-generation of quilt.1 to work with dash
>  The echo command of dash interprets \f as a special characer and
>  thus generates a bad manual page. bash's echo leaves them unchanged
>  (it needs -e to replace those special characters). Using printf
>  instead is a portable solution that work with both shells.
>  .
>  The code also uses a bashism ($'') but it's not really needed with
>  GNU sed at least (it understands \t and \n) so drop it and avoid some
>  painful double escaping.
>  .
>  This patch should be sent upstream.
> Author: Raphaël Hertzog 
> Forwarded: 111223 to upstream mailing list by Martin Quinson
> Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/quilt/+bug/402237
> Bug-Debian: http://bugs.debian.org/563517
> 
> ---
>  Makefile.in |4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> --- a/Makefile.in
> +++ b/Makefile.in
> @@ -196,7 +196,7 @@ doc/README : doc/README.in $(QUILT:%=qui
>   $(MAKE) -s reference\
>   ;;  \
>   *)  \
> - echo $$line \
> + printf "%s\n" "$$line"  \
>   ;;  \
>   esac ;  \
>   done 2>&1 < $< > $@
> @@ -208,11 +208,11 @@ doc/quilt.1: doc/quilt.1.in $(QUILT:%=qu
> '@REFERENCE''@')  \
>   $(MAKE) -s reference |  \
>   $(SED) -e 's/^quilt \([^ ]*\)\(.*\)/.IP "\\fB\1\\fP\2 " 4/' \
> --e $$'s/^  \\(-[^\t]*\\)\t\\?/.IP "\\1" 8\\\n/'  \
> --e $$'s/^  \t\\?//'  \
> +-e 's/^  \(-[^\t]*\)\t\?/.IP "\1" 8\n/'  \
> +-e 's/^  \t\?//' \
>   ;;  \
> *)\
> - echo "$$line"   \
> + printf "%s\n" "$$line"  \
>   ;;  \
> esac; \
>   done < $< 2>&1 > $@

> ___
> Quilt-dev mailing list
> Quilt-dev@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/quilt-dev


-- 

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] 0.50 in Debian + Simple patch for inclusion: Fix manpage generation under dash

2011-12-23 Thread Martin Quinson
Hello,

Raphaël packaged 0.50 for Debian a few days ago, and so far it all
goes rather well. Only some glitches against the packaging itself were
reported, nothing against the code.

Also, now that we are on par with upstream code, we'd like to reduce a
bit the amount of patches that we have in the package. For the record,
our series file contains 16 patches, several of them being rather
simple. I'm proposing a first one, in attachement. If nobody complains
in the next few days, I'll commit it myself before proceeding to the
next patch.

It may seem like a noisy way of integrating our stuff, but I prefer to
play safe with quilt. It's heavily used and I feel my technical limits
here. So, sorry for the noise, but that's how I'll do it. If you
prefer, the whole patch serie is available here:
http://git.debian.org/?p=collab-maint/quilt.git

Thanks, and happy chrismas,
Mt.

-- 
Thou shalt foreswear, renounce, and abjure the vile heresy which claimeth
that ``All the world's a 386'', and have no commerce with the benighted
heathens who cling to this barbarous belief, that the days of thy program
may be long even though the days of thy current machine be short.
  -- Tenth commandment of the C programmer
Description: Fix auto-generation of quilt.1 to work with dash
 The echo command of dash interprets \f as a special characer and
 thus generates a bad manual page. bash's echo leaves them unchanged
 (it needs -e to replace those special characters). Using printf
 instead is a portable solution that work with both shells.
 .
 The code also uses a bashism ($'') but it's not really needed with
 GNU sed at least (it understands \t and \n) so drop it and avoid some
 painful double escaping.
 .
 This patch should be sent upstream.
Author: Raphaël Hertzog 
Forwarded: 111223 to upstream mailing list by Martin Quinson
Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/quilt/+bug/402237
Bug-Debian: http://bugs.debian.org/563517

---
 Makefile.in |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/Makefile.in
+++ b/Makefile.in
@@ -196,7 +196,7 @@ doc/README : doc/README.in $(QUILT:%=qui
$(MAKE) -s reference\
;;  \
*)  \
-   echo $$line \
+   printf "%s\n" "$$line"  \
;;  \
esac ;  \
done 2>&1 < $< > $@
@@ -208,11 +208,11 @@ doc/quilt.1: doc/quilt.1.in $(QUILT:%=qu
  '@REFERENCE''@')  \
$(MAKE) -s reference |  \
$(SED) -e 's/^quilt \([^ ]*\)\(.*\)/.IP "\\fB\1\\fP\2 " 4/' \
-  -e $$'s/^  \\(-[^\t]*\\)\t\\?/.IP "\\1" 8\\\n/'  \
-  -e $$'s/^  \t\\?//'  \
+  -e 's/^  \(-[^\t]*\)\t\?/.IP "\1" 8\n/'  \
+  -e 's/^  \t\?//' \
;;  \
  *)\
-   echo "$$line"   \
+   printf "%s\n" "$$line"  \
;;  \
  esac; \
done < $< 2>&1 > $@
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] docdir

2011-12-07 Thread Martin Quinson
This rational sounds perfectly ok to me (as debian packager). I only
skimed through the patch but I trust you on this side.

Bye, Mt.

On Wed, Dec 07, 2011 at 12:09:24PM +0100, Jean Delvare wrote:
> Hi all,
> 
> I would like to fix an issue with docdir when building/installing quilt, 
> and am seeking for opinions and comments.
> 
> Initially my problem is that quilt doesn't install its documentation 
> where I (Suse packager) would like it to, and it won't let me change it 
> through configure options, so I have to patch Makefile.in when building 
> the package. This has a maintenance cost I'd like to get rid of. The 
> cause of the problem is that
> 
>   $(docdir)/$(PACKAGE)-$(VERSION)
> 
> is being hard-coded 6 times in Makefile.in, so you have to change it 
> that many times if you want a different location. And I do want to 
> change it because the standard path for documentation files on Suse (and 
> Debian, FWIW) is /usr/share/doc/$(PACKAGE) and not 
> /usr/share/doc/$(PACKAGE)-$(VERSION) [1].
> 
> While trying to solve this first problem, I noticed two additional 
> problems, which are related so I believe that all three problems should 
> be solved at once.
> 
> Problem #2 is that ./configure --help says:
> 
>   --docdir=DIRdocumentation root [DATAROOTDIR/doc/quilt]
> 
> but the default value of $(docdir) is actually set to $(datadir)/doc 
> later in the configure script. This is both misleading and a lack of 
> flexibility (back to problem #1).
> 
> Problem #3 is that ./configure also looks at $RPM_DOC_DIR and uses that 
> as the default value for $(docdir) if defined. It seems wrong to me that 
> an upstream source package should care about package management specific 
> things. Even though I know rpm is part of the LSB, it would seem more 
> logical to me that the quilt.spec file of an rpm-based distribution 
> would call ./configure --docdir=${RPM_DOC_DIR}/quilt if needed (which is 
> currently not possible due to the Makefile.in implementation, see 
> problem #1), and the configure script itself wouldn't contain references 
> to rpm. As a matter of fact, I couldn't find any other configure script 
> which looks at $RPM_DOC_DIR, and I'm not quite sure why quilt would be 
> different in this respect.
> 
> Andreas, according to git blame, you did add this part of configure.ac:
> 
> dnl Determine where package documentation is supposed to go
> if test -n "$RPM_DOC_DIR" ; then
> docdir="$RPM_DOC_DIR"
> else
> docdir='$(datadir)/doc'
> fi
> 
> The commit message did not really enlighten me. Can you please explain 
> what problem you were trying to solve? I'd like to get rid of the above, 
> as doing so (plus other adjustments) solves all 3 problems.
> 
> [1] As far as I can see, the naming scheme used by Suse and Debian is 
> also what autoconf-generated configure scripts use by default, which 
> makes it a de-facto standard IMHO.
> 
> The patch I have in mind goes along these lines:
> 
> ---
>  Makefile.in  |   13 +++--
>  configure.ac |7 +--
>  2 files changed, 8 insertions(+), 12 deletions(-)
> 
> --- a/Makefile.in
> +++ b/Makefile.in
> @@ -1,6 +1,7 @@
>  PACKAGE :=   @PACKAGE_NAME@
>  VERSION :=   @PACKAGE_VERSION@
>  RELEASE :=   @PACKAGE_RELEASE@
> +PACKAGE_TARNAME := @PACKAGE_TARNAME@
>  PACKAGE_BUGREPORT := @PACKAGE_BUGREPORT@
>  
>  prefix :=@prefix@
> @@ -213,7 +214,7 @@ doc/quilt.1: doc/quilt.1.in $(QUILT:%=qu
>   ;;  \
> *@DOCSUBDIR@*)\
>   echo "$$line" | \
> - $(SED) -e 's:@DOCSUBDIR''@:$(docdir)/$(PACKAGE)-$(VERSION):g' \
> + $(SED) -e 's:@DOCSUBDIR''@:$(docdir):g' \
>   ;;  \
> *)\
>   echo "$$line"   \
> @@ -272,7 +273,7 @@ $(patsubst %.in,%,$(wildcard bin/*.in qu
>   -e 's:@RELEASE''@:$(RELEASE):g' \
>   -e 's:@ETCDIR''@:$(etcdir):g'   \
>   -e 's:@LOCALEDIR''@:$(localedir):g' \
> - -e 's:@DOCSUBDIR''@:$(docdir)/$(PACKAGE)-$(VERSION):g'  \
> + -e 's:@DOCSUBDIR''@:$(docdir):g'\
>   $< > $@
>   @$(if $(filter-out $<,$(NON_EXEC_IN)),chmod +x $@)
>  
> @@ -331,11 +332,11 @@ endif
>   $(INSTALL) -d $(BUILD_ROOT)$(libdir)/$(PACKAGE)
>   $(INSTALL) -m 755 $(LIB:%=lib/%) $(BUILD_ROOT)$(libdir)/$(PACKAGE)/
>  
> - $(INSTALL) -d $(BUILD_ROOT)$(docdir)/$(PACKAGE)-$(VERSION)/
> + $(INSTALL) -d $(BUILD_ROOT)$(docdir)/
>   $(INSTALL) -m 644 doc/README\
> -$(BUILD_ROOT)$(docdir)/$(PACKAGE)-$(VERSION)/
> +$(BUILD_ROOT)$(docdir)/
>   

Re: [Quilt-dev] [PATCH 00/39] Reimplement backup-files in bash

2011-12-05 Thread Martin Quinson
On Mon, Dec 05, 2011 at 10:10:40PM +0100, Jean Delvare wrote:
> 
> Oh well, I'll do better next time...

At least, you did it [instead of me, for example]. I feel really
grateful.

Thanks for your time,
Mt.

-- 
There are three kinds of lies -- lies, damned lies, and statistics.
   -- Benjamin Disraeli, British Prime Minister

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH 00/39] Reimplement backup-files in bash

2011-09-28 Thread Martin Quinson
On Wed, Sep 28, 2011 at 12:56:43AM +0200, Martin Quinson wrote:
> On Mon, Sep 26, 2011 at 06:25:47PM +0200, Jean Delvare wrote:
> > Hi Andreas,
> > 
> > On Thursday 15 September 2011 04:19:49 pm Andreas Gruenbacher wrote:
> > > On Thursday 15 September 2011 15:15:37 Jean Delvare wrote:
> > > > Andreas, do you have a release schedule for quilt? I think a new
> > > > version is long overdue.
> > > 
> > > I don't.  Are you or Martin interested in making a release?
> > 
> > I could do it this week, if nobody else volunteers. I'm just a little 
> > frightened to mess it all up, as I've never released anything based on 
> > git. Do we have a document explaining the various steps to follow?
> 
> I still have a little patch on documentation laying around in Debian.
> I'd like to commit it upstream before the release if possible. It took
> me quite some times to retrieve my credentials on savannah since the
> email corresponding to the account was closed too, but I'm back.
> 
> I'll try to do so tomorrow.

I'm done, feel free to release. If you want, I'm willing to give a
hand per IM here.

> Feel free to contact me through IM for fast synchronization if you want.
> http://www.loria.fr/~quinson/Contact/


Bye, Mt.

-- 
User n.: A programmer who will believe anything you tell him.

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH 00/39] Reimplement backup-files in bash

2011-09-27 Thread Martin Quinson
On Mon, Sep 26, 2011 at 06:25:47PM +0200, Jean Delvare wrote:
> Hi Andreas,
> 
> On Thursday 15 September 2011 04:19:49 pm Andreas Gruenbacher wrote:
> > On Thursday 15 September 2011 15:15:37 Jean Delvare wrote:
> > > Andreas, do you have a release schedule for quilt? I think a new
> > > version is long overdue.
> > 
> > I don't.  Are you or Martin interested in making a release?
> 
> I could do it this week, if nobody else volunteers. I'm just a little 
> frightened to mess it all up, as I've never released anything based on 
> git. Do we have a document explaining the various steps to follow?

I still have a little patch on documentation laying around in Debian.
I'd like to commit it upstream before the release if possible. It took
me quite some times to retrieve my credentials on savannah since the
email corresponding to the account was closed too, but I'm back.

I'll try to do so tomorrow.

Feel free to contact me through IM for fast synchronization if you want.
http://www.loria.fr/~quinson/Contact/

Thanks for your time,
Mt.

-- 
Get a clue, or a dictionary.  -- example of mutual love on debian-devel

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [PATCH] Force locale to C when generating date for From header

2011-09-15 Thread Martin Quinson
Hello, 

yet another trivial patch that shouldn't cause any harm. I feel bad
that it took me more than 3 years to submit it..

Thanks, Mt.

-- 
Computers make very fast, very accurate mistakes.
From: Simon Horman 
Date: Thu, 19 Apr 2007 17:39:07 +0900
Subject: Force locale to C when generating date for From header

Without this the From header will end up with a date according
to the pervailing locale, which I believe results in an invalid
mbox - muttng doesn't like it anyway.

Tested with the following environment:

# LANG=ja_JP.utf8
LANGUAGE=ja_JP.utf8
LC_CTYPE="ja_JP.utf8"
LC_NUMERIC="ja_JP.utf8"
LC_TIME="ja_JP.utf8"
LC_COLLATE="ja_JP.utf8"
LC_MONETARY="ja_JP.utf8"
LC_MESSAGES="ja_JP.utf8"
LC_PAPER="ja_JP.utf8"
LC_NAME="ja_JP.utf8"
LC_ADDRESS="ja_JP.utf8"
LC_TELEPHONE="ja_JP.utf8"
LC_MEASUREMENT="ja_JP.utf8"
LC_IDENTIFICATION="ja_JP.utf8"
LC_ALL=ja_JP.utf8

Upstream status: submitted on 110915

---
 quilt/mail.in |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: b/quilt/mail.in
===
--- a/quilt/mail.in
+++ b/quilt/mail.in
@@ -137,7 +137,7 @@
| ${QUILT_SENDMAIL:-sendmail} \
${QUILT_SENDMAIL_ARGS--f "$opt_sender"} "$@"
else
-   local from_date=$(date "+%a %b %e %H:%M:%S %Y")
+   local from_date=$(LC_ALL=C date "+%a %b %e %H:%M:%S %Y")
echo "From $opt_sender_address $from_date"
sed -e 's/^From />From /' $tmpfile
echo
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH 00/39] Reimplement backup-files in bash

2011-09-15 Thread Martin Quinson
On Thu, Sep 15, 2011 at 04:19:49PM +0200, Andreas Gruenbacher wrote:
> On Thursday 15 September 2011 15:15:37 Jean Delvare wrote:
> > Hi Raphael,
> > 
> > On Thursday 16 June 2011 10:26:47 am Raphael Hertzog wrote:
> > > And it would be nice to have a new quilt release with this code.
> > 
> > You're preaching the choir here. The lack of release is actually what 
> > prevented me from committing my changes. It is a large and intrusive 
> > change, no matter how much care I put in it and how much testing I gave 
> > it. Unfortunately, with no release in 2.5 years, it's pretty clear that 
> > most distributions are packing development repository snapshots and not 
> > version 0.48. So many users are likely to receive my commits very 
> > quickly. I'm not sure if we want this.
> 
> I'm not sure if any distros would want to switch to a "released" version.

In debian, we are not packaging a git snapshot, and resync with you
guys only on release points. We almost never cherry pick commits from
your git, unless when they actually fix a bug reported by our users.

In that sens, I'd be more than interested in a new release. Actually,
my plan was to push all the trivial patches that we have, and possibly
some non-trivial patches, and after that see if we can get a release
out. 

I'd prefer to push all these trivia before the release because it'll
ease the merge afterward.

> > Andreas, do you have a release schedule for quilt? I think a new version 
> > is long overdue.
> 
> I don't.  Are you or Martin interested in making a release?

You mean tag the git, build an archive and push it to savannah or
something more profund? If I still have my savannah credentials, I may
try to do it.

> > Once we have a new release, I'll be happy to commit my work.
> 
> Alright.

Integrating Jean's work is also something I'd love. His work is far
better than what we have in Debian, but I already have issues tracking
upstream given the amount of patches that we have here, I don't feel
like tracking 2 separate upstreams ;)

I guess that a big part of the issue is that I don't use quilt myself
on my day to day work, so I easily get rotten about it. Moreover, I
feel very limited about my bash scripting skills, and I definitely
don't want to take any [big] responsability in changing the code. 

Bye, Mt.

-- 
Ouvrir une école, c'est fermer une prison.
-- Victor Hugo
[Openning a school comes down to close a jail]

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] Let /etc/mailname override the hostname in the mail command

2011-09-15 Thread Martin Quinson
On Thu, Sep 15, 2011 at 04:12:43PM +0200, Andreas Gruenbacher wrote:
> On Thursday 15 September 2011 16:00:53 Martin Quinson wrote:
> > On Thu, Sep 15, 2011 at 03:03:26PM +0200, Andreas Gruenbacher wrote:
> > > On Thursday 15 September 2011 14:41:22 Martin Quinson wrote:
> > > > Hello,
> > > > 
> > > > here is an old patch laying in the debian package. It is maybe a bit
> > > > debian specific, but it shouldn't cause any arm to other systems, and
> > > > I'd really like to reduce the divergences between debian's version and
> > > > common one.
> > > 
> > > I agree.  How about the slightly simplified attached version though?
> > 
> > Your version is indeed much superior to what we had. I already replace
> > it here.
> 
> Okay, I've pushed this with your comment, with you as the author; tell me if 
> you disagree.

Boarf. I won't be that picky but consider that this is just perfect
this way.

Thanks, Mt.

-- 
First they ignore you, then they laugh at you, then they fight you,
then you win.--- Mahatma Gandhi

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] Let /etc/mailname override the hostname in the mail command

2011-09-15 Thread Martin Quinson
On Thu, Sep 15, 2011 at 03:03:26PM +0200, Andreas Gruenbacher wrote:
> On Thursday 15 September 2011 14:41:22 Martin Quinson wrote:
> > Hello,
> > 
> > here is an old patch laying in the debian package. It is maybe a bit
> > debian specific, but it shouldn't cause any arm to other systems, and
> > I'd really like to reduce the divergences between debian's version and
> > common one.
> 
> I agree.  How about the slightly simplified attached version though?

Your version is indeed much superior to what we had. I already replace
it here.

Thanks, Mt.


> diff --git a/quilt/mail.in b/quilt/mail.in
> index d16b3c1..b9b73b1 100644
> --- a/quilt/mail.in
> +++ b/quilt/mail.in
> @@ -267,7 +267,13 @@ fi
>  
>  if [ -z "$opt_sender" ]
>  then
> - hostname=$(hostname -f 2>/dev/null)
> + if [ -e /etc/mailname ]
> + then
> + hostname=$(< /etc/mailname)
> + else
> + hostname=$(hostname -f 2>/dev/null)
> + fi
> +
>   if [ "$hostname" = "${hostname/.}" ]
>   then
>   hostname=$(hostname)


-- 
Le sens commun n'est pas si commun (Common sense is not so common).
  -- Voltaire

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


Re: [Quilt-dev] [PATCH] missing create_db call when snapshot'ing

2011-09-15 Thread Martin Quinson
On Thu, Sep 15, 2011 at 02:10:33PM +0200, Andreas Gruenbacher wrote:
> On Thursday 15 September 2011 12:03:39 Martin Quinson wrote:
> > Hello all,
> > 
> > this is an old patch laying in the debian package and that could
> > actually benefit to all of us.
> 
> Looks good, thanks.  I've pushed it.

Thanks a lot. I'll try to find the time to push some of the simplest
debian patches to you guys in the next. It'd be great if we could
reduce the differences between debian version and yours to zero,
everyone would benefit of it.

Thanks again for quick reaction,
Mt.

-- 
You have a problem and decide to use regexps. Now you have two problems.
 -- Old Computer Engineers saying

___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


[Quilt-dev] [PATCH] Let /etc/mailname override the hostname in the mail command

2011-09-15 Thread Martin Quinson
Hello,

here is an old patch laying in the debian package. It is maybe a bit
debian specific, but it shouldn't cause any arm to other systems, and
I'd really like to reduce the divergences between debian's version and
common one.

Thanks for reviewing and integrating.
Mt.

-- 
Le sens commun n'est pas si commun (Common sense is not so common).
  -- Voltaire
Let /etc/mailname override the hostname in the mail command

Closes bug http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=356348

Initial patch author said (in above bug report):
 When generating the default From: for outbound messages quilt uses
 $(hostname -f) to determine the domain part of the e-mail address.
 Policy 11.6 specifies that this should be overridden by the value
 specified in /etc/mailname.

 (see 
http://www.debian.org/doc/debian-policy/ch-customized-programs.html#s-mail-transport-agents)

Upstream status: 
 * Submitted 060427, never answered.
 * Resubmitted 110915

---
 quilt/mail.in |   12 +++-
 1 file changed, 11 insertions(+), 1 deletion(-)

Index: b/quilt/mail.in
===
--- a/quilt/mail.in
+++ b/quilt/mail.in
@@ -263,7 +263,17 @@
 
 if [ -z "$opt_sender" ]
 then
-   hostname=$(hostname -f 2>/dev/null)
+   hostname=nowhere
+   if [ -e /etc/mailname ] ; 
+   then
+   hostname=`cat /etc/mailname`
+   fi
+   
+   if [ "$hostname" = "${hostname/.}" ]
+   then
+   hostname=$(hostname -f 2>/dev/null)
+   fi
+   
if [ "$hostname" = "${hostname/.}" ]
then
hostname=$(hostname)
___
Quilt-dev mailing list
Quilt-dev@nongnu.org
https://lists.nongnu.org/mailman/listinfo/quilt-dev


  1   2   >