【发布时间】:2015-05-27 07:31:41
【问题描述】:
当我执行 git status 时,netbeans private.xml 会出现问题,我尝试在 git ignore 中添加几种方法。但 gitignore 根本不会忽略它。
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)
(use "git checkout -- <file>..." to discard changes in working directory)
modified: .gitignore
modified: nbproject/private/private.xml
...
我的 git 忽略文件是
node_modules/
dist/
*.log
nbproject/private/*
*.bak
*.orig
*~
*.log
*private.xml
都试过了 nbproject/私人/* 和 *private.xml 在同一个文件中。
【问题讨论】: