Q
Git和符号链接
1
A
回答
1
1)不要git add
那么任何符号链接。这包括诸如git add -A
之类的东西以及不会自动添加目前未被跟踪的东西。
2)git rm <symlink>
;重复每个符号链接,然后git commit
。当然,你需要在每个分支上做到这一点。另外,如果您想要删除项目历史中的所有符号链接,则需要在每次提交时执行相同的操作,这可以使用git filter-branch
完成。
15
添加所有的符号链接.gitignore
find . -type l >> .gitignore
删除所有符号链接,从库
find . -type l -exec git rm --cached {} \;
+0
这解决了我的问题。我已经尝试了第一条线,但第二条是做到了。 – 2016-09-15 12:36:02
相关问题
- 1. Linux,符号链接的Dir,Meld和git
- 2. 添加符号链接的Git仓库
- 3. Git初始化符号链接
- 4. 如何让Git忽略符号链接?
- 5. 无法从git删除符号链接
- 6. 符号链接
- 7. 符号链接
- 8. 符号链接CMake
- 9. 符号链接自
- 10. 两个符号链接之间的符号链接
- 11. node_modules:符号链接还是不符号链接?
- 12. Apache的符号链接符号链接返回HTTP 500错误
- 13. 将相对符号链接转换为绝对符号链接
- 14. nodejs,github,npm和符号链接
- 15. subrepo,hg克隆和符号链接
- 16. TYPO3扩展和符号链接
- 17. gcc包含路径和符号链接
- 18. .bash_profile和脚本作为符号链接
- 19. 跨服务器符号链接和Crontab
- 20. Windows中的PHP和符号链接
- 21. JFileChooser和NTFS JunctionPoints /符号链接?
- 22. ACL和符号链接问题
- 23. CarbonEmacs,符号链接和dired-find-file
- 24. Unix中的硬链接和符号链接
- 25. Linux硬链接(ln)和GIT
- 26. git和变音符号
- 27. git嵌套仓库 - 子模块与符号链接与其他
- 28. 何时在git中使用子模式vs符号链接
- 29. Git是没有忽略一个符号链接
- 30. 在共享(符号链接)目录中使用Git
此外,添加任何符号链接到'.gitignore'。 – Wilduck 2013-03-08 22:34:28