I have a working directory structure like the below one :
mercurial_working_dir:
- project1
- project2
- project3
Under each project folder there are common folders that i want to untrack from mercurial.e.g: i dont want any file to be tracked under /metadata folder which is common at the 3 projects. As far as i know i should use hg remove -Af command with the specifing files.Is there any way to define regular exps at the command in order to recursively "remove" the current version of any file under the metadata folder which is placed at all my 开发者_如何学Pythonprojects?
Take a look at the chapter about file names and pattern matching in the mercurial book. You can use a pattern like this:
hg rm "glob:**/metadata/**"
If you prefer regular expressions, you can also use the re:
prefix instead of glob:
.
精彩评论