(Visual)SVN 通过正则表达式忽略文件 [英] (Visual)SVN ignore files by Regex

查看:42
本文介绍了(Visual)SVN 通过正则表达式忽略文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要排除具有以下模式的文件:

I need to exclude files with the following pattern:

ProjectFoo.Data[0-9]{14}.lgp

ProjectFoo.Data[0-9]{14}.lgp

如何将 RegEx 用于 (Visual)SVN 忽略列表?

How can I use RegEx for (Visual)SVN ignore list?

推荐答案

subversion 忽略列表不支持正则表达式.它们被实现为 glob/file 模式.

The subversion ignore list don't support regular expressions. They are implemented as glob/file patterns.

这些模式不支持 {14} 重复结构.

These patterns don't support the {14} repeat construct.

模式

ProjectFoo.Data[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9].lgp

应该按照您的要求做,但我建议使用 ProjectFoo.Data[0-9]*.lgp 之类的东西,因为这样就足够好"了.

should do what you ask, but I would recommend using something like ProjectFoo.Data[0-9]*.lgp as that would be 'good enough'.

这篇关于(Visual)SVN 通过正则表达式忽略文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆