1

In my /.git/info/exclude file I have placed two directories and a file:

workspace
data
config.php

All of which are in the root. While 'workspace' and 'data' are being ignored, config.php is pushing.

Tunaki
  • 125,519
  • 44
  • 317
  • 399
Fluidbyte
  • 4,982
  • 7
  • 42
  • 72

1 Answers1

2

You need to remove config.php from the git repo index first, if you want it to be ignored.

 git rm --cached config.php

(See for instance "Making git “forget” about a file that was tracked but is now “.gitignored")

Plus, ignoring directory should be specify with an '/' at the end of your line:

workspace/
data/
Community
  • 1
  • 1
VonC
  • 1,129,465
  • 480
  • 4,036
  • 4,755