什麼是最好的(或儘可能好的)一般SVN忽略模式使用?最佳一般SVN忽略模式?
有許多不同的IDE,編輯器,編譯器,插件,平臺等具體文件和某些文件類型的「重疊」(即希望某些類型的項目,不是爲別人)。
然而,有大量的文件類型,你永遠不想自動包含在源代碼管理中,而不管你的開發環境的具體細節如何。
回答這個問題,將作爲一個很好的起點任何項目 - 只要求他們加入他們所需要的一些環境特定項目。它也可以適用於其他版本控制系統(VCS)。
什麼是最好的(或儘可能好的)一般SVN忽略模式使用?最佳一般SVN忽略模式?
有許多不同的IDE,編輯器,編譯器,插件,平臺等具體文件和某些文件類型的「重疊」(即希望某些類型的項目,不是爲別人)。
然而,有大量的文件類型,你永遠不想自動包含在源代碼管理中,而不管你的開發環境的具體細節如何。
回答這個問題,將作爲一個很好的起點任何項目 - 只要求他們加入他們所需要的一些環境特定項目。它也可以適用於其他版本控制系統(VCS)。
我將我自己的兩分錢添加到這個問題:
我使用以下的SVN忽略在TortoiseSVN和Subversion的CLI本地C++,在Windows和Linux下C#/ VB.NET和Perl項目模式平臺。這對我來說很有效!
格式適用於複製和粘貼:
*.o *.lo *.la #*# .*.rej *.rej .*~ *~ .#* .DS_Store thumbs.db Thumbs.db *.bak *.class *.exe *.dll *.mine *.obj *.ncb *.lib *.log *.idb *.pdb *.ilk *.msi* .res *.pch *.suo *.exp *.*~ *.~* ~*.* cvs CVS .CVS .cvs release Release debug Debug ignore Ignore bin Bin obj Obj *.csproj.user *.user *.generated.cs
格式化爲可讀性:
*.o *.lo *.la #*# .*.rej *.rej .*~ *~ .#* .DS_Store thumbs.db Thumbs.db *.bak *.class *.exe *.dll *.mine *.obj *.ncb *.lib *.log *.idb *.pdb *.ilk *.msi* .res *.pch *.suo *.exp *.*~ *.~* ~*.* cvs CVS .CVS .cvs release Release debug Debug ignore Ignore bin Bin obj Obj *.csproj.user *.user *.generated.cs
@blorgbeard - 我回滾你的格式更改,因爲我相信最好將它全部放在一行上,以便複製/粘貼到SVN配置文件(不接受多行輸入)。 – 2009-07-12 16:25:13
調整它。 – 2009-07-17 17:11:08
* .tmp * .temp呢? – 2009-07-17 17:15:09
用於我的Visual Studio項目
*/bin */obj *.user *.suo
你可以從那裏擴展更多的文件類型。
Windows用戶可能希望在的desktop.ini和的Thumbs.db扔。
的Visual Studio(VC++)的用戶一定要排除.NCB文件
每當我遇到一個文件我一般不希望在倉庫,我更新的模式。我相信沒有「最好」的模式 - 它總是取決於你開發的語言和環境。
此外,你不太可能想到所有可能的「可忽略的」文件類型 - 你會總是遇到一個你忘記包含的文件類型。這就是爲什麼更新模式,你走的最好。
Mac用戶可能需要在.DS_Store扔。此外,如果有Dev的使用Emacs或Vim的,你可能要添加〜〜#和#。
的模式取決於你使用的操作系統。
在Linux上,您需要先封鎖**。o *,**。so *,**。a *和**。la *。您可能還想阻止**〜*(來自編輯的備份文件)和#*#(來自崩潰的emacs備份)。
在Windows上,您至少需要** .obj *,**。lib *和** .dll *。
您需要阻止的任何其他文件取決於您的IDE,編輯器和編譯器。
對於Eclipse,我用:
bin
.*
*得到所有的項目配置。你幾乎從不想檢入一個「隱藏的」目錄或文件,但如果它出現,你仍然可以添加它。
由於您可能使用第三方庫和dll作爲項目的一部分,所以我沒有看到從存儲庫中阻止* .lib和* .dll的智慧。這些是要存儲在存儲庫中的東西。
基於魁梧的忽略模式,我加入ReSharper的到忽略列表
格式適用於複製和粘貼:
*.o *.lo .la ## .*.rej .rej .~ ~ .# .DS_Store thumbs.db Thumbs.db *.bak *.class *.exe *.dll *.mine *.obj *.ncb *.lib *.log *.idb *.pdb *.ilk .msi .res *.pch *.suo *.exp ~. cvs CVS .CVS .cvs release Release debug Debug ignore Ignore bin Bin obj Obj *.csproj.user *.user _ReSharper.* *.resharper.user
格式化爲可讀性:
*.o *.lo .la ## .*.rej .rej .~ ~ .# .DS_Store thumbs.db Thumbs.db *.bak
*.class *.exe *.dll *.mine *.obj *.ncb *.lib *.log *.idb *.pdb *.ilk .msi .res *.pch *.suo *.exp ~. cvs
CVS .CVS .cvs release Release debug
Debug ignore Ignore bin Bin obj Obj
*.csproj.user *.user _ReSharper.* *.resharper.user
我忽略模式的Visual Studio:
*/bin */obj */Release */Debug *.suo *.err *.log *.obj *.bin *.dll *.exe *.LOG *.user *.pdb [tT]emp [tT]empPE Ankh.Load thumbs.db *.resharper *.vspscc *.vsssccc *.scc */_ReSharper* */_ReSharper.* bin obj *.resharperoptions *.db *.bak *_ReSharper* *.snk logs output TestResults *.crunchsolution.* *.crunchproject.*
格式化爲可讀性
*/bin */obj */Release */Debug *.suo *.err *.log *.obj *.bin *.dll *.exe *.LOG *.user *.pdb [tT]emp [tT]empPE Ankh.Load thumbs.db *.resharper *.vspscc *.vsssccc *.scc */_ReSharper* */_ReSharper.* bin obj *.resharperoptions *.db *.bak *_ReSharper* *.snk logs output TestResults *.crunchsolution.* *.crunchproject.*
得,如果你使用一個添加ReSharper的的組合。
另外一個看出來的是安赫*。*
Visual Studio 2010個的用戶應該添加ipch
(用於任何類型的項目使用智能感知大文件)(一個包含C++預編譯頭文件夾),*.sdf
。
不要忘記NCrunch臨時文件:
*.crunchsolution.* *.crunchproject.*
和核心轉儲(Cygwin的,LINUX)
*.stackdump core.*
gitignore.io提供可配置模式的飯桶。他們提供了一個可讀的列表,您需要重新格式化SVN。
例如,requesting MicrosoftOffice and Windows返回
# Created by https://www.gitignore.io/api/microsoftoffice,windows
### MicrosoftOffice ###
*.tmp
# Word temporary
~$*.doc*
# Excel temporary
~$*.xls*
# Excel Backup File
*.xlk
# PowerPoint temporary
~$*.ppt*
# Visio autosave temporary files
*.~vsdx
### Windows ###
# Windows image file caches
Thumbs.db
ehthumbs.db
# Folder config file
Desktop.ini
# Recycle Bin used on file shares
$RECYCLE.BIN/
# Windows Installer files
*.cab
*.msi
*.msm
*.msp
# Windows shortcuts
*.lnk
gitignore.io提供可配置模式的飯桶。他們提供了一個可讀的列表,您需要重新格式化SVN。
例如,requesting MicrosoftOffice and Windows回報
# Created by https://www.gitignore.io/api/microsoftoffice,windows
### MicrosoftOffice ###
*.tmp
# Word temporary
~$*.doc*
# Excel temporary
~$*.xls*
# Excel Backup File
*.xlk
# PowerPoint temporary
~$*.ppt*
# Visio autosave temporary files
*.~vsdx
### Windows ###
# Windows image file caches
Thumbs.db
ehthumbs.db
# Folder config file
Desktop.ini
# Recycle Bin used on file shares
$RECYCLE.BIN/
# Windows Installer files
*.cab
*.msi
*.msm
*.msp
# Windows shortcuts
*.lnk
看來,它可以直接用作svn:global-ignore
您好扎克,我一直在閱讀這篇文章你的:HTTP://www.zachburlingame。 com/2011/03 /安裝 - mercurial-and-hosting-repositories-with-centos /和我有幾個問題..有沒有辦法與你聯繫?感謝您的時間... P.S:找不到任何其他方式與您聯繫,除非通過這裏的評論,對於煩惱抱歉 – Brams 2014-07-09 08:56:20