diff -r ba58c5a61503 -r 43b5fe18ea6c mercurial/win32.py --- a/mercurial/win32.py Tue Mar 29 16:25:48 2011 +0200 +++ b/mercurial/win32.py Mon Mar 28 15:54:22 2011 +0200 @@ -58,6 +58,7 @@ # SetFileAttributes _FILE_ATTRIBUTE_NORMAL = 0x80 +_FILE_ATTRIBUTE_NOT_CONTENT_INDEXED = 0x2000 # Process Security and Access Rights _PROCESS_QUERY_INFORMATION = 0x0400 @@ -365,3 +366,8 @@ # Leaking a tempfile is the lesser evil than aborting here and # leaving some potentially serious inconsistencies. pass + +def makedir(path, notindexed): + os.mkdir(path) + if notindexed: + _kernel32.SetFileAttributesA(path, _FILE_ATTRIBUTE_NOT_CONTENT_INDEXED)