Tag: gitignore

Sourcetree adding files in global .gitignore, not in repository .gitignore

I am using SourceTree for my GIT repositories. Today I need to ignore some files; when I added these files to ignore list from SourceTree’s “Ignore file” menu and check local .gitignore file, the ignored files are not listed there. Instead these are listed in the global .gitignore. How can I get SourceTree to add […]

Un-ignore all files in global .gitignore

After looking at git ignore exception, I realized that one can ignore files in a repository from a global .gitignore file. Is there any way that you can override all rules from the global .gitignore file, so that the repository will have everything in it and nothing ignored? (besides un-ignoring every file individually)

How do I push files specified in .gitignore?

If I have a “vendors” directory in my .gitignore, is there a way I can set up a remote that will receive that directory anyway when I do a push?

Git ignore is not ignoring the netbeans private files

When ever I do git status, the netbeans private.xml is making trouble, I tried adding that in git ignore several ways. but the gitignore simply does not ignore it. git status On branch master Your branch is up-to-date with ‘origin/master’. Changes not staged for commit: (use “git add <file>…” to update what will be committed) […]

.gitignore blank in Windows Explorer

Why is my .gitignore file blank in Windows (7) Explorer? Note that both the .htaccess file and the .git folder appear as expected. See http://prntscr.com/6rmhk1 (The standard StackOverflow image system isn’t working on my corporate network – probably being blocked).

Should I include .sass-cache with the repo when versioning a web project?

When creating a new project or upgrading an older one, should I conclude the .sass-cache directory in the repo? Since that is always changing and depends on the preprocessor to run wouldn’t it be easier to ignore? What are the benefits of including the cache dirs?

.gitignore does not work for **/*.xyz

My git project contains .cas files that I do not want to be pushed to the repository. I thus added the line **/*.cas to my .gitignore file but .cas files would still appear in git status. After reading through numerous other posts I checked for the .gitignore entries to not have trailing white spaces and […]

Visual Studio Online Git – How to make sure /packages are ignored?

Is my .gitignore even working? I added packages folder to it and it still wants to commit all my packages on every commit. What I’m doing at the moment is excluding package folder on every commit which is horrible. Am I missing something or it is bug within Visual Studio/Visual Studio Online Git System? .gitignore […]

Git: Ignore only content of the folder

I use the following .gitignore file (global): .idea .svn /media/covers/* /media/tmp/* /media/cache/* /bin /include /lib /local *.log *.pot *.pyc local_settings.py So in media/covers, media/tmp, media/cache I want to ignore all files and folders, but not this directories themselves. This .gitignore file ignore media/covers, media/tmp, media/cache dirs, how can I fix it? TIA!

How to tell git to ignore a certain file if and only if another file exists?

I’d like to tell git to ignore a file named foo.ext if and only if there exists another file named foo.txe. I am almost sure that this cannot be done with the .gitignore syntax but there are maybe other tricky ways that I do not think of? Example of use: I frequently store the figures […]

Git Baby is a git and github fan, let's start git clone.