I can't add the hidden file to git repo. Force (-f --force) does not help. This file is not included in .gitignore as well. It's silent (even with verbose flag) as the file is added, though it is not displayed in status, not actually added. File name is .profile, Is this name restricted for some reasons?
Asked
Active
Viewed 1,527 times
1
-
How do you add it? – axiac Apr 06 '17 at 18:18
-
I'm wondering if perhaps ```git update-index``` is somehow involved. Don't know how git add would react if you had already specified that a file should be ```--asume-unchanged```. – eftshift0 Apr 06 '17 at 18:20
-
There is not enough information here to answer your question. Include the exact commands and outputs that you get in your question. – 1615903 Apr 07 '17 at 04:46
-
I tried `git add .profile` , `git add -f .profile` and `git add --force .profile` . I got no output. It does not appear on the tracked list. Actually it doesn't appear on untracked list as well. When I rename it for example to .prof it works. Surprisingly, other repo on my computer behaves normally with this file. It has rather nothing to do with .gitignore, as even deleting it doesn't help. I also rather didn't change any settings. – kmichael08 Apr 09 '17 at 17:19
-
Well, when I typed `git rm .profile` it appeared on erased list. After copying this file again it started behaving normally. No clue what happened. – kmichael08 Apr 09 '17 at 17:20
-
Well, that means that the file was already added and no changes had been made to it. – 1615903 Apr 12 '17 at 08:26
1 Answers
0
No way, just check this repo https://raw.githubusercontent.com/tpyolang/.profile
Also make sure your global ignore file is ok.
git config --global core.excludesfile

SingleSeeker
- 19
- 5