![]() This got all of my repositories to show up that were located in c:/webdata/hg_repos/trunk. The backslashes and forward slashes make a difference. \webdata\hg_repos\trunk = /webdata/hg_repos/trunk Repository collections still work if they are on the same drive as your CGI though. This bug was fixed in Mercurial 1.1.x (see next section). There is a bug with not working with Windows drive letters - Mercurial misinterprets the colon as a variable separator. The advice here is to run `hg update null` on the served repository to avoid any superfluous recursive search. This will search inside every directory of the repository, this might be extremely slow if executed on a repository containing a working directory. The prefix name may be the root - just the '/'. Multiple collections may be specified, however each must have a unique prefix (part before the =). This causes all repositories under c:/webdata/hg_repos/trunk to show up (whereas a simple * does not look for nested ones). To avoid scanning more than one subdirectory, use one asterisk (*) instead of two (**). Warning: Browsing the available repositories will be very slow, as all the files and subdirectories are scanned every time. This has been introduced in Mercurial 1.1 For old versions see the next section. The advised way of specifying collection is now the section. Either way, hopefully this saves you some time. I don't know if this is a Mercurial/Python issue or an Apache issue. Repo2 = c:/webdata/merc.repos/web/htdocs/ Repo2 = c:/webdata/rc/web/htdocs/Īnd instead I had to change my directory names to Maybe this is just my weird Apache setup, but when my hgwebdir.cgi was installed in c:/webdata/repos, this nfig failed for me: The path to your Mercurial repositories cannot also contain the name to the path to the Mercurial CGI. Move the Templates folder from my MERCURIAL_HOME\Templates to MERCURIAL_HOME\lib\Templates. (Although you're supposed to be able to specify templates = c:/dev/Mercurial/lib in Mercurial.ini or nfig, neither option worked for me.) ![]() The CGI assumes templates are located inside of the lib directory you just created. You can do this by enabling mod_env and using the following setting in Apache: If you continue to see import errors even after adjusting sys.path, you may need to turn on Python's optimize mode so it can import. If you compiled your own version of Mercurial, you do not need the line. Ex:ġ # adjust python path if not a system-wide install: 2 import sys 3 sys. The first line of hgwebdir.cgi must point to your Python executable. If you do wish to use Python 2.6, you must build your own Mercurial WindowsInstall. The pre-compiled Windows binaries for Mercurial 1.0.x, 1.1.x, 1.2.x and 1.3.x were compiled with Python 2.5. Otherwise, you'll get "Invalid Magic Number" errors when trying to run the CGI.Īt least one installer for 0.9.5 uses Python 2.4. On Windows, your Python version must match the version used to compile Mercurial. OpenBSD 4.6 Specific Instructions for chrooted Apache 1.3.29 One way would be to get the latest version from the stable branch:īe sure to check for later versions, these filenames and versions might be out of date.ĥ. If you can only get a pre-1.0 version from your distribution, you should probably acquire another version somehow. If you are on Linux, you probably want to install the Mercurial version packaged by your distribution. Hgwebdir.cgi (use the one coming with your Mercurial package or download from ) you will need the python2.4-dev package as well. ![]() some version of mercurial (mine was 0.9 taken from Debian/unstable). ![]() ![]() The free version of Abyss Web Server works well under windows
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |