|
![]() | ![]() | ![]() |
![]() | ![]() |
![]() |
Mercurial SupportOne of the major feature, implemented in EmForge-0.26 is No InterWiki reference defined in properties for Wiki called "ttp"! support. This project created here only for including demo of mercurial-based repository browser. Mercurial support done as part of Extended Maven-SCM project by extending standard maven-scm-provider-hg with 4 extended "remote commands". How to configure EmForge to use MercurialTo be able to browse Mercurial repository from EmForge you need:
As soon, as you will have everything installed, you can create new project and EmForge and set something like scm:hg:/path/to/your/repositoryas repository path in project settings. After it browser will be available from "Sources" link on project page, like it is available for this project: http://www.emforge.org/project/MercurialSupport/browser Technical details of implementationHere described how remote commands implementedrlistrlist command should return list of files under some folder in specified revision (optional, if missed - tip version is used) in remote repository.To get list of files in specified revision manifest command it used: hg manifest -rxxxmanifest command returned ALL files in repository, so, we should filter returned list to get only files under specified folder. Since for each file we need to return also information about it's latest revision (date, author, comment) we call hg -rxxx -l1 path/to/fileto get latests revision information for each file. This way looks not to be very optimal - but - I do not found way to get list of files in some revision under only some folder (not whole repository like manifest returned), as well as get latest revision information for bundle of files (not for each individual file) rlogfor getting history for some path (folder or file) we callhg log /some/pathand returns this information rcatfor getting file contents we calls 2 commands:
hg -rxxx cat /path/to/file hg -rxxx -l1 /path/to/file rinfoto get information about some specific file we get file information (folder/normal file, name and so on) from file-system (since we are working with local repository), and call "hg log" to get latest revision infoThis way looks not too good (I will prefer to get informatino about specific file by using hg commands) - but I do not found any way to do it via hg commands 3814 Views
| ![]() | |||
![]() | ![]() | ![]() | |||
|