Handle defconfig as .config in .gitignore and distclean.
PATCH 1/1 Handle defconfig as .config in .gitignore and distclean.
From: Karoly Kasza <[email protected]>
After using "make safedefconfig", a defconfig file appears which is an extract of the .config file. When running git, it incorrectly detects it as a source code change, while make distclean forgets to remove it.
This patch adds /defconfig to .gitignore and to the distclean Makefile target.
--- .gitignore | 1 + Makefile | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-)
.gitignore +1 -0
@@ -5,6 +5,7 @@ /.config.old /..config.tmp /.config +/defconfig *.depend *.o /*.patch
Makefile +1 -1
@@ -814,7 +814,7 @@ endif ifeq ($(O),output) rm -rf $(O) endif - rm -rf $(BR2_CONFIG) $(CONFIG_DIR)/.config.old $(CONFIG_DIR)/..config.tmp \ + rm -rf $(BR2_CONFIG) $(CONFIG_DIR)/defconfig $(CONFIG_DIR)/.config.old $(CONFIG_DIR)/..config.tmp \ $(CONFIG_DIR)/.auto.deps help:
Signature · 1 line
1.7.10.4
PATCH 1/1 Handle defconfig as .config in .gitignore and distclean.
I'm not sure I like that...
people are told to work with a clone of buildroot and adding defconfig
to gitignore means that ther is a high chance of not adding it to git
and loosing it...
(i'm perfectly fine with the distclean part)
Cordialement
J?r?my Rosen
+33 (0)1 42 68 28 04
fight key loggers : write some perl using vim
Open Wide Ingenierie
23, rue Daviel
75013 Paris - France
www.openwide.fr
----- Mail original -----
Quoted 52 lines
From: Karoly Kasza <[email protected]>
After using "make safedefconfig", a defconfig file appears which is an
extract of the .config file. When running git, it incorrectly detects it as a
source code change, while make distclean forgets to remove it.This patch adds /defconfig to .gitignore and to the distclean
Makefiletarget.Signed-off-by Karoly Kasza <[email protected]>--- .gitignore | 1 + Makefile | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-).gitignore +1
-0@@ -5,6 +5,7 @@ /.config.old /..config.tmp /.config +/defconfig *.depend *.o /*.patchMakefile +1
-1@@ -814,7 +814,7 @@ endif ifeq ($(O),output) rm -rf $(O) endif - rm -rf $(BR2_CONFIG) $(CONFIG_DIR)/.config.old $(CONFIG_DIR)/..config.tmp \ + rm -rf $(BR2_CONFIG) $(CONFIG_DIR)/defconfig $(CONFIG_DIR)/.config.old $(CONFIG_DIR)/..config.tmp \ $(CONFIG_DIR)/.auto.depshelp:
--
1.7.10.4_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
PATCH 1/1 Handle defconfig as .config in .gitignore and distclean.
Hi Jeremy,
Thanks for reviewing!
people are told to work with a clone of buildroot and adding defconfig
Quoted 3 lines
to gitignore means that ther is a high chance of not adding it to git
and loosing it...
You are right in this context, but .config is also in .gitignore, which also shouldn't be there if a custom repo is used.
I think .gitignore should be tuned to the git repo currently used - buildroot's own repo in the vanilla BR case.
Best regards,
Karoly
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20150520/a35097b0/attachment.html>
PATCH 1/1 Handle defconfig as .config in .gitignore and distclean.
K?roly, All,
I'm trying to review the oldest patches still pending, and here's it's the turn of your patch. ;-)
On 2015-05-20 13:13 +0200, K?roly Kasza spake thusly:
Quoted 8 lines
people are told to work with a clone of buildroot and adding defconfig
Quoted 2 lines
to gitignore means that ther is a high chance of not adding it to git
and loosing it...You are right in this context, but .config is also in .gitignore, which also shouldn't be there if a custom repo is used.
I think .gitignore should be tuned to the git repo currently used - buildroot's own repo in the vanilla BR case.
Unlike Jeremy, I'm perfectly fine with defconfig in .gitignore. It's the distclean part I'm more concerned with.
On the one hand, it does make sense to remove it like we do remove .config. After all, the user is king, and if he wants to remove everything, why should we keep it? ;-)
On the other hand, I would see defconfig as really the quintessence of the configuration, which the user explicitly saved. They could get quite surprised if we now remove that file.
So, I'm a bit skeptical either way: keep it or remove it, I am unsure. Let's lean toward the safe side, and ket's just keep it, for users that were used to that behaviour, OK?
Regards,
Yann E. MORIN.
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
PATCH 1/1 Handle defconfig as .config in .gitignore and distclean.
Hello,
Quoted 7 lines · Yann E. MORIN
Unlike Jeremy, I'm perfectly fine with defconfig in .gitignore. It's the distclean part I'm more concerned with.
On the one hand, it does make sense to remove it like we do remove .config. After all, the user is king, and if he wants to remove everything, why should we keep it? ;-)
Quoted 7 lines
On the other hand, I would see defconfig as really the quintessence of the configuration, which the user explicitly saved. They could get quite surprised if we now remove that file.
So, I'm a bit skeptical either way: keep it or remove it, I am unsure. Let's lean toward the safe side, and ket's just keep it, for users that were used to that behaviour, OK?
Since the defconfig file name is configurable (by means of BR2_DEFCONFIG), I don't think we should do anything special with it. So I don't think it should be in .gitignore and I don't think we should remove it upon "make distclean".
If we were do "rm -f $(BR2_DEFCONFIG)" to always remove the user configured defconfig, then it would remove configs/<foo>_defconfig if you started from that defconfig and do a "make distclean". Not good. And we can't have user-configurable file names in .gitignore I believe.
So I'm personally in favor of keeping things as they are today, and therefore reject the patch proposed by K?roly.
Best regards,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH 1/1 Handle defconfig as .config in .gitignore and distclean.
Thomas, K?roly, All,
On 2015-12-28 09:20 +0100, Thomas Petazzoni spake thusly:
Quoted 22 lines · Yann E. MORIN
Quoted 8 lines
Unlike Jeremy, I'm perfectly fine with defconfig in .gitignore. It's the distclean part I'm more concerned with.
On the one hand, it does make sense to remove it like we do remove .config. After all, the user is king, and if he wants to remove everything, why should we keep it? ;-)
Quoted 7 lines
On the other hand, I would see defconfig as really the quintessence of the configuration, which the user explicitly saved. They could get quite surprised if we now remove that file.
So, I'm a bit skeptical either way: keep it or remove it, I am unsure. Let's lean toward the safe side, and ket's just keep it, for users that were used to that behaviour, OK?
Since the defconfig file name is configurable (by means of
BR2_DEFCONFIG), I don't think we should do anything special with it. So I don't think it should be in .gitignore and I don't think we should remove it upon "make distclean".
Quoted 7 lines
If we were do "rm -f $(BR2_DEFCONFIG)" to always remove the user configured defconfig, then it would remove configs/<foo>_defconfig if you started from that defconfig and do a "make distclean". Not good. And we can't have user-configurable file names in .gitignore I believe.
So I'm personally in favor of keeping things as they are today, and therefore reject the patch proposed by K?roly.
That's fine with me. I'll mark it rejected, then.
Regards,
Yann E. MORIN.
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'