tags:

views:

41

answers:

1

Edit:

Thanks msw, omnifarious and tonfa for your answers. Although the example I gave was one of my main uses for propset, omnifarious & tonfa answered the general question as well. The specific question of including tags into text files was solved by this question.

Thanks for your help.

Original question: " I use subversion keywords like Date, Author, Revision number etc in my LaTeX projects to include the revision details in the typeset document. I tried searching for an equivalent to svn propset command in mercurial, but couldn't find it. A sample command in subversion would be:

svn propset svn:keywords "Date Author Rev" sample.tex

Are there any equivalent commands in mercurial I could use to replace keywords inside a text file under revision control with corresponding details?"

+2  A: 

svn propset has many, many uses aside from setting up keyword substitution. Your question is asking about the existence of a general mechanism to solve a specific problem. You should restate your question to ask about the specific problem you want to solve.

And you would discover that, in fact, there is a mechanism for doing keyword substitution in Mercurial. But it bears very little resemblance to the svn propset mechanism. The KeywordExtension is distributed as part of the standard Mercurial distribution and has been since Mercurial 1.1.

Mercurial has no equivalent to svn propset in the general case. Mercurial stores very limited meta-data about individual files. It stores whether or not the file is an executable, a link, or whether a particular version is a copy of some other file in the repository. And that's it. There is no general mechanism in Mercurial for storing meta-data about a file.

Omnifarious