[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Quilt-dev] [patch] add option to "quilt refresh" to save original v
From: |
Olaf Dabrunz |
Subject: |
Re: [Quilt-dev] [patch] add option to "quilt refresh" to save original version of a patch |
Date: |
Fri, 14 Oct 2005 18:35:18 +0200 |
User-agent: |
Mutt/1.5.9i |
On 13-Oct-05, Dean Roehrich wrote:
> On Thu, Oct 13, 2005 at 08:41:51PM +0200, Olaf Dabrunz wrote:
> > This patch adds option "--orig" to "quilt refresh". It saves the
> > original version of a patch as patch.orig.
>
> I haven't used 'quilt fork', but this sounds like the same thing. If it's
> different, then perhaps it should at least name its files the way 'quilt fork'
> names them.
Having "--orig" in "quilt refresh" (and since I revised the patch, in
"quilt header") makes it simple to always have a backup copy of the
original patch. Just put something like this into $HOME/.quiltrc:
-------------------------------------------------------------
QUILT_REFRESH_ARGS='-p0 --sort --backup --orig --diffstat'
QUILT_HEADER_ARGS='--backup --orig'
-------------------------------------------------------------
A "quilt fork" can be forgotten. And you have to check whether you
already called "quilt fork" or not.
The main difference is that "--orig" makes it simple to always have the
last released revision of a patch available so that you can compare with
the revision under development.
The suffix ".orig" was used for these reasons:
- It is different from the suffixes for forks, making it clear that no
fork was generated and that work will continue on the current fork
(or "head") of the patch.
- If work continues on a fork of a patch rather than on the "head", an
"*.orig" file will also be generated for the fork. In this way the
forking point and the newest version remain visible and changes can
be revised. (I would not take this use too far though, forks can be
handled better by version control systems.)
- Several Makefiles (e.g. the main Makefile for the Linux kernel) have
"mrproper" (or similar) targets that remove "*.orig" files before a
release.
You may argue that "*~" is used even more often and patches usually
do not lie around in source trees. But "*~" is for normal backups
and forks so "*.orig" is still the most obvious choice. And if
patches and the corresponding "*.orig" files happen to lie around in
a source tree, this extension makes it easier to clean up.
- The option is supposed to mirror the use of ":set patchmode=.orig"
in vim. The help on "patchmode" mentions the use of "*.org" and
"*.orig". I do not see the former used (maybe since DOS systems are
dying out) but I see the latter more or less often.
If there is demand for it, I can make the extension configurable.
(Adding an optional argument to "--orig" and using the environment
variable QUILT_ORIG sounds workable.)
Regards,
--
Olaf Dabrunz (od/odabrunz), SUSE Linux Products GmbH, Nürnberg