* [patch] preserve symlinked .configs
@ 2001-05-17 12:01 Andrew Morton
2001-05-17 12:44 ` Marko Kreen
0 siblings, 1 reply; 2+ messages in thread
From: Andrew Morton @ 2001-05-17 12:01 UTC (permalink / raw)
To: lkml
When one has several machines it is nice to keep each
machine's .config under revision control. Then, on
each machine,
ln [-s] .config-$(hostname -s) .config
Problem is, `make menuconfig/oldconfig/config' goes and
removes your link, causing much irritation.
--- linux-2.4.4-ac9/scripts/Configure Sun Dec 31 13:16:13 2000
+++ ac/scripts/Configure Sun May 6 09:40:25 2001
@@ -566,9 +566,10 @@
rm -f .config.old
if [ -f .config ]; then
- mv .config .config.old
+ cp .config .config.old
fi
-mv .tmpconfig .config
+cp .tmpconfig .config
+rm .tmpconfig
mv .tmpconfig.h include/linux/autoconf.h
echo
--- linux-2.4.4-ac9/scripts/Menuconfig Tue May 15 14:11:09 2001
+++ ac/scripts/Menuconfig Wed May 9 11:33:30 2001
@@ -1290,12 +1290,12 @@
if [ -f "$DEF_CONFIG" ]
then
- rm -f ${DEF_CONFIG}.old
- mv $DEF_CONFIG ${DEF_CONFIG}.old
+ cp $DEF_CONFIG ${DEF_CONFIG}.old
fi
- mv $CONFIG $DEF_CONFIG
-
+ cp $CONFIG $DEF_CONFIG
+ rm $CONFIG
+
return 0
else
return 1
-
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [patch] preserve symlinked .configs
2001-05-17 12:01 [patch] preserve symlinked .configs Andrew Morton
@ 2001-05-17 12:44 ` Marko Kreen
0 siblings, 0 replies; 2+ messages in thread
From: Marko Kreen @ 2001-05-17 12:44 UTC (permalink / raw)
To: Andrew Morton; +Cc: lkml
On Thu, May 17, 2001 at 10:01:33PM +1000, Andrew Morton wrote:
> When one has several machines it is nice to keep each
> machine's .config under revision control. Then, on
> each machine,
>
> ln [-s] .config-$(hostname -s) .config
>
> Problem is, `make menuconfig/oldconfig/config' goes and
> removes your link, causing much irritation.
IMHO currect behaviour is the Right Thing. Think of 'cp -al' on
trees. Patching one does not affect another, because patch()
does not modify files, it creates new file. If I use your patch
and have 'cp -al'-d trees which happen to have .config inside,
doing 'make *config' in one tree will affect another. Thats
wrong.
--
marko
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2001-05-17 12:43 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-05-17 12:01 [patch] preserve symlinked .configs Andrew Morton
2001-05-17 12:44 ` Marko Kreen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).