Ignore part of the directory in mercurial

I need to ignore the directory, but track one subfolder of this directory. The tree of my files looks like this:

root
 -d1
  --bin
  --bin/data
 -d2
  --bin
  --bin/data

I need to ignore the bin directory, but keep track of the bin / data directory in all the folders of my repo. Now I use:

syntax: glob
*/obj/*
*/bin/*
*.swp

but when I run the hg status, I don’t see if there is anything new in my dirs data.

Thank!

+3
source share
1 answer

I think this will do what you need.

syntax: glob
*/obj/*
*.swp

syntax: regexp
/bin/(?!data)
+8
source

Source: https://habr.com/ru/post/1796418/


All Articles