svn java.mine_最好的一般SVN忽略模式?

回答(17)

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

我会在这个问题上加上我自己的两分钱:

我在Windows和Linux平台上对TortoiseSVN和Subversion CLI使用以下SVN忽略模式,用于本机C,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

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

根据Burly的忽略模式,我将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

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

我对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.*

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

每次我遇到一个文件,我通常不想在存储库中,我更新模式 . 我相信没有"best"模式 - 它始终是你发展的 .

而且,你不太可能想到所有可能的“可忽略的”文件类型 - 你总会遇到一个你忘记包含的文件类型 . 这就是为什么在你去的时候更新模式效果最好 .

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

Windows用户可能想要输入desktop.ini和thumbs.db .

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

用于我的Visual Studio项目

*/bin */obj *.user *.suo

您可以从那里扩展更多文件类型 .

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

Visual Studio(VC)用户肯定需要排除 .ncb 文件

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

Mac用户可能想要投入.DS_Store . 另外,如果有开发人员使用Emacs或Vim,你可能想添加~~和## .

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

对于Eclipse,我使用:

bin

.*

. *获取所有项目配置 . 您几乎从不想要检查“隐藏”目录或文件,但如果它出现,您仍然可以添加它 .

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

由于您可能正在使用第三方库和dll作为项目的一部分,因此我没有看到从存储库中阻止* .lib和* .dll的智慧 . 这些是要存储在存储库中的内容 .

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

Visual Studio 2010用户应添加 ipch (包含C预编译头文件夹的文件夹)和 *.sdf (intellisense用于任何类型项目的大文件) .

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

该模式取决于您使用的操作系统 .

在Linux上,你要阻止** . o ,* . so ,* . a 和* . la 开头 . 您可能还想阻止*〜(编辑备份文件)和##(崩溃时的emacs备份) .

在Windows上,你至少需要** .obj ,* . lib 和* . dll * .

您需要阻止的任何其他文件取决于您的IDE,编辑器和编译器 .

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

如果您使用Resharper,请将其添加到混合物中 .

另一个要注意的是Ankh * . *

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

别忘了NCrunch临时文件:

*.crunchsolution.* *.crunchproject.*

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

和核心转储(cygwin,linux)

*.stackdump core.*

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

gitignore.io为git提供可配置的模式 . 它们提供了一个可读列表,您需要重新格式化SVN .

# 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

e15298c6a3b4591803e154ab0c3b3e2e.png

2 years ago

gitignore.io为git提供可配置的模式 . 它们提供了一个可读列表,您需要重新格式化SVN .

# 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

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值