mercurial - How do I make files with a specific extension be added to a commit automatically? -


i'm trying figure out how automatically add files of extension (for example *.tex) commit dialogue (the checkbox should checked! don't want search new files every single time)

i tried adding *.tex auto-commit list (=comma separated list) doesn't anything.

mercurial has called hooks stuff automatically on events. see hgrc documentation , mercurial wiki page on hooks.

your task can done pre-commit hook, defined in repository's hgrc file:

[hooks] pre-commit = hg add -i "*.tex" 

before commit, hook automatically adds not yet tracked tex files in root of repository's current working directory. adjust value of -i option or add more -i options specify more complex patterns of files add automatically.

note: don't use tortoisehg, cannot if hook causes checkboxes pre-selected. anyway, should work if commit tortoisehg.


Comments

Popular posts from this blog

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -

java - Android recognize cell phone with keyboard or not? -

iphone - How would you achieve a LED Scrolling effect? -