From: kai.grossjohann@uni-duisburg.de (Kai Großjohann)
To: gentoo-dev@gentoo.org
Cc: gentoo-user@gentoo.org
Subject: [gentoo-dev] Re: etc-update & ._cfg* files: major issue with gentoo?
Date: Mon, 06 Jan 2003 08:25:17 +0100 [thread overview]
Message-ID: <841y3qloyq.fsf@lucy.cs.uni-dortmund.de> (raw)
In-Reply-To: 33052.192.168.0.8.1041817268.squirrel@webmail.codewordt.co.uk
"Dhruba Bandopadhyay" <dhruba@codewordt.co.uk> writes:
> When emerging packages configuration files beginning with ._cfg* are left
> in /etc and other locations and on subsequent emerges portage warns that
> one has X number of files remaining. Now, on many occassions I have had
> several of these files on my system and have postponed dealing with them
> simply because they are a hassle. Once in a while however, I use
> etc-update to sort them with care.
>
> There are many problems with the way this is done for a non-expert user
> (which may include myself) and the ones below are only a few of them.
I think part of the problem is the display of the differences.
Suppose you install a package for the first time which installs
version A of /etc/foo. You change this file manually, giving version
B. Sometime later you install a new version of that package which
comes with version C of the file.
Now if you ask etc-update for a diff, it shows you the differences
between versions B and C. However, these differences partly stem
from the changes you made between A and B, and partly they depend on
the changes the upstream version had between A and C.
I think it would be more useful to show the differences between A and
C. Then etc-update could ask whether these differences should be
integrated into the current version. When the user says yes, then B
is patched with the A->C diff, giving a new version D. (Or maybe C
should be patched with the A->B diff? Probably it doesn't make a
difference.) This process can introduce conflicts (if B and C changed
the same line). Then users might have to resolve these conflicts.
Personally, I use cfengine to circumvent such problems: I never edit
config files manually, I just let cfengine do it for me. Then, when
a new version of a config file is to be installed, I just tell the
system to install it, and then I run cfengine which incorporates my
changes into the new version.
This requires some thought when writing cfengine scripts. You have
to anticipate in which way the syntax of the config file might change
and then design your editing operations so that they will still work
with the changed syntax. Of course, when the config file syntax has
changed radically, then this automatic method will fail. I guess
that if you design the editing scripts sensibly, then you will see
such failures easily. (The program doesn't start because of syntax
errors, or the cfengine edit script complains it can't find anything
to edit.)
But even in the cfengine case, it would be useful to stash the
original versions of config files somewhere such that a diff between
A and C could be requested.
What do people think?
--
Ambibibentists unite!
--
gentoo-dev@gentoo.org mailing list
next prev parent reply other threads:[~2003-01-06 8:43 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-01-06 1:41 [gentoo-dev] etc-update & ._cfg* files: major issue with gentoo? Dhruba Bandopadhyay
2003-01-06 2:27 ` [gentoo-dev] " Brian Jackson
2003-01-06 5:24 ` Viktor Lakics
2003-01-06 6:03 ` Brian Jackson
2003-01-06 10:49 ` Jeremy Wohl
2003-01-06 6:40 ` Joseph Carter
2003-01-06 7:25 ` Kai Großjohann [this message]
2003-01-06 10:26 ` Toby Dickenson
2003-01-06 13:15 ` Thomas T. Veldhouse
2003-01-06 13:02 ` Bengt Gorden
2003-01-10 11:10 ` Kai Großjohann
2003-01-10 15:25 ` Brian Hall
2003-01-10 15:33 ` Oliver Rutherfurd
2003-01-06 15:20 ` Joseph Carter
2003-01-06 7:37 ` [gentoo-dev] " Sven Vermeulen
[not found] ` <200301060054.29991.absinthe@pobox.com>
2003-01-10 22:38 ` [gentoo-dev] " Kai Großjohann
2003-01-10 23:05 ` William Kenworthy
2003-01-11 1:48 ` Joseph Carter
2003-01-11 10:14 ` Kai Großjohann
2003-01-11 15:19 ` [gentoo-dev] Diff alternatives for etc-update (WAS: etc-update & ._cfg* files: major issue with gentoo?) Dylan Carlson
[not found] ` <84hecfmmpb.fsf@lucy.cs.uni-dortmund.de>
2003-01-11 21:29 ` [gentoo-dev] Re: Diff alternatives for etc-update Dylan Carlson
2003-01-11 21:44 ` Paul de Vrieze
2003-01-11 23:59 ` Dylan Carlson
2003-01-13 22:39 ` [gentoo-dev] Diff alternatives for etc-update (WAS: etc-update & ._cfg* files: major issue with gentoo?) Peter Ruskin
2003-01-13 22:50 ` Dylan Carlson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=841y3qloyq.fsf@lucy.cs.uni-dortmund.de \
--to=kai.grossjohann@uni-duisburg.de \
--cc=gentoo-dev@gentoo.org \
--cc=gentoo-user@gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox