gitignore: Add .DS_Store for Mac OS X

Submitted by Bryan Hundven on Sept. 29, 2014, 10:46 p.m.

Details

Message ID 1412030761-40604-1-git-send-email-bryanhundven@gmail.com
State New
Headers show

Commit Message

Bryan Hundven Sept. 29, 2014, 10:46 p.m.
From: Bryan Hundven <bryan@Bryans-MacBook-Pro.local>

Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
---
 .gitignore | 3 +++
 1 file changed, 3 insertions(+)

Comments

Baruch Siach Sept. 30, 2014, 4:47 a.m.
Hi Bryan,

On Mon, Sep 29, 2014 at 03:46:01PM -0700, Bryan Hundven wrote:
> From: Bryan Hundven <bryan@Bryans-MacBook-Pro.local>

This can't be right.

> Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
> ---
>  .gitignore | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/.gitignore b/.gitignore
> index 90b516d..c1af0a1 100644
> --- a/.gitignore
> +++ b/.gitignore
> @@ -21,3 +21,6 @@ build.log
>  .build/
>  # .. and the legacy location
>  targets/
> +
> +# Mac OS X .DS_Store file
> +.DS_Store

Instead of adding this file to each and every software project .gitignore, why 
not why not add it to your local $HOME/.config/git/ignore file? See 
core.excludesfile in the git-config(1) man page.

baruch
Baruch Siach Sept. 30, 2014, 7:40 a.m.
Hi Bryan,

On Mon, Sep 29, 2014 at 10:18:15PM -0700, Bryan Hundven wrote:

[snip]

> diff --git a/.gitignore b/.gitignore
> index 90b516d..c1af0a1 100644
> --- a/.gitignore
> +++ b/.gitignore
> @@ -21,3 +21,6 @@ build.log
> .build/
> # .. and the legacy location
> targets/
> +
> +# Mac OS X .DS_Store file
> +.DS_Store
> 
> 
> Instead of adding this file to each and every software project .gitignore,
> why
> not why not add it to your local $HOME/.config/git/ignore file? See
> core.excludesfile in the git-config(1) man page.
> 
> 
> Is it really that horrible to have two extra lines in a .gitignore file to
> make sure we don't let users accidentally include this file in a commit?
> (functionally, it's really one line, but the comment kind of helps)

I'll let the maintainer decide on that. But I think it would be much easier 
for you to set $HOME/.config/git/ignore once, and solve the problem for all 
your git trees.

Just my 2ยข.

baruch

Patch hide | download patch | download mbox

diff --git a/.gitignore b/.gitignore
index 90b516d..c1af0a1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -21,3 +21,6 @@  build.log
 .build/
 # .. and the legacy location
 targets/
+
+# Mac OS X .DS_Store file
+.DS_Store