Re: Beginner problem with .gitignore

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Kai Schlamp venit, vidit, dixit 20.04.2009 19:57:
> Hello.
> 
> I have a file called TitleAreaDialog.java in the folder
> my_path\org.eclipse.jface\src\org\eclipse\jface\dialogs
> 
> .git and .gitignore is in the my_path\ folder (using Git Cygwin on Windows).
> 
> Now I everything is ignored from org.eclipse.jface, but not that 
> TitleAreaDialog.java
> 
> So I specified the following in .gitignore:
> /org.eclipse.*
> !TitleAreaDialog.java
> 
> I also tried it with:
> !Title*, 
> !/org.eclipse.jface/src/org/eclipse/jface/dialogs/TitleAreaDialog.java
> 
> but the TitleAreaDialog is always ignored as well.

By "is ignored", do you mean that git status doesn't show it? git status
does not recurse into subdirectories by default unless there is at least
one tracked file inside.

> 
> What do I have to do to not ignore this file specifically?

Have you ever added that file?

If you only want to track a few files it's easiest to ignore everything
and git add those files. Once added they will be tracked no matter what
the ignore patterns say.

Michael
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]