Re: moving config files
Norbert Preining <preining@logic.at> wrote:
> Hi friends!
>
> I am in need of an advice: Can someone give me a quick howto how to move
> config files from an old location to a new location? Do I need some
> version checking?
Since the package never was in Debian, and will probably stay in
experimental for a while, wouldn't it be wise to not support upgrades at
all, and only remove the old files if they are unchanged?
> Does this seem ok?
Do the files differ? I hope not; if they would, you'd get a bogus
"Configuration file created by you or by a script" message from dpkg,
and ucf is currently the only working solution - except not supporting
upgrades, which would be the better choice.
If the files do not differ, I think you can do it with the code you
showed.
> On a side note: the function move_old_conffile() in tetex-bin.preinst
> seems to be a bit strange:
> rm $oldname
> if rmdir $oldname 2>/dev/null; then
> echo "Removed obsolete dir $oldname."
> fi
> I guess the rmdir $oldname should be a rmdir $olddir. Did nobody happend
> to stumble on this?
Obviously not - I even had problems stumbling over it now, because it's
in tetex-base. Fixed in svn.
Bye, Frank
--
Frank Küster
Inst. f. Biochemie der Univ. Zürich
Debian Developer
Reply to: