All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] Handle defconfig as .config in .gitignore and distclean.
@ 2015-05-20  8:45 kaszak at gmail.com
  2015-05-20  9:04 ` Jeremy Rosen
  0 siblings, 1 reply; 6+ messages in thread
From: kaszak at gmail.com @ 2015-05-20  8:45 UTC (permalink / raw)
  To: buildroot

From: Karoly Kasza <kaszak@gmail.com>

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.

Signed-off-by: Karoly Kasza <kaszak@gmail.com>
---
 .gitignore |    1 +
 Makefile   |    2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/.gitignore b/.gitignore
index bb02d9f..66f5ac1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -5,6 +5,7 @@
 /.config.old
 /..config.tmp
 /.config
+/defconfig
 *.depend
 *.o
 /*.patch
diff --git a/Makefile b/Makefile
index 5c4293b..bc890dd 100644
--- a/Makefile
+++ b/Makefile
@@ -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:
-- 
1.7.10.4

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH] Handle defconfig as .config in .gitignore and distclean.
  2015-05-20  8:45 [Buildroot] [PATCH] Handle defconfig as .config in .gitignore and distclean kaszak at gmail.com
@ 2015-05-20  9:04 ` Jeremy Rosen
  2015-05-20 11:13   ` Károly Kasza
  0 siblings, 1 reply; 6+ messages in thread
From: Jeremy Rosen @ 2015-05-20  9:04 UTC (permalink / raw)
  To: buildroot

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 -----
> From: Karoly Kasza <kaszak@gmail.com>
> 
> 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.
> 
> Signed-off-by: Karoly Kasza <kaszak@gmail.com>
> ---
>  .gitignore |    1 +
>  Makefile   |    2 +-
>  2 files changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/.gitignore b/.gitignore
> index bb02d9f..66f5ac1 100644
> --- a/.gitignore
> +++ b/.gitignore
> @@ -5,6 +5,7 @@
>  /.config.old
>  /..config.tmp
>  /.config
> +/defconfig
>  *.depend
>  *.o
>  /*.patch
> diff --git a/Makefile b/Makefile
> index 5c4293b..bc890dd 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -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:
> --
> 1.7.10.4
> 
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
> 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH] Handle defconfig as .config in .gitignore and distclean.
  2015-05-20  9:04 ` Jeremy Rosen
@ 2015-05-20 11:13   ` Károly Kasza
  2015-12-27 20:44     ` Yann E. MORIN
  0 siblings, 1 reply; 6+ messages in thread
From: Károly Kasza @ 2015-05-20 11:13 UTC (permalink / raw)
  To: buildroot

Hi Jeremy,

Thanks for reviewing!

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...
>

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>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH] Handle defconfig as .config in .gitignore and distclean.
  2015-05-20 11:13   ` Károly Kasza
@ 2015-12-27 20:44     ` Yann E. MORIN
  2015-12-28  8:20       ` Thomas Petazzoni
  0 siblings, 1 reply; 6+ messages in thread
From: Yann E. MORIN @ 2015-12-27 20:44 UTC (permalink / raw)
  To: buildroot

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:
> 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...
> 
> 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.

-- 
.-----------------.--------------------.------------------.--------------------.
|  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.  |
'------------------------------^-------^------------------^--------------------'

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH] Handle defconfig as .config in .gitignore and distclean.
  2015-12-27 20:44     ` Yann E. MORIN
@ 2015-12-28  8:20       ` Thomas Petazzoni
  2015-12-28 17:24         ` Yann E. MORIN
  0 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni @ 2015-12-28  8:20 UTC (permalink / raw)
  To: buildroot

Hello,

On Sun, 27 Dec 2015 21:44:16 +0100, Yann E. MORIN wrote:

> 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?

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
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH] Handle defconfig as .config in .gitignore and distclean.
  2015-12-28  8:20       ` Thomas Petazzoni
@ 2015-12-28 17:24         ` Yann E. MORIN
  0 siblings, 0 replies; 6+ messages in thread
From: Yann E. MORIN @ 2015-12-28 17:24 UTC (permalink / raw)
  To: buildroot

Thomas, K?roly, All,

On 2015-12-28 09:20 +0100, Thomas Petazzoni spake thusly:
> On Sun, 27 Dec 2015 21:44:16 +0100, Yann E. MORIN wrote:
> 
> > 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?
> 
> 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.

That's fine with me. I'll mark it rejected, then.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  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.  |
'------------------------------^-------^------------------^--------------------'

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-12-28 17:24 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-20  8:45 [Buildroot] [PATCH] Handle defconfig as .config in .gitignore and distclean kaszak at gmail.com
2015-05-20  9:04 ` Jeremy Rosen
2015-05-20 11:13   ` Károly Kasza
2015-12-27 20:44     ` Yann E. MORIN
2015-12-28  8:20       ` Thomas Petazzoni
2015-12-28 17:24         ` Yann E. MORIN

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.