Admin/Mercurial/hgwebdir.cgi
changeset 40385 b70ef70733e8
parent 28930 6d677da7b339
equal deleted inserted replaced
40384:5edaca742d7e 40385:b70ef70733e8
     2 #
     2 #
     3 # An example CGI script to export multiple hgweb repos, edit as necessary
     3 # An example CGI script to export multiple hgweb repos, edit as necessary
     4 
     4 
     5 # adjust python path if not a system-wide install:
     5 # adjust python path if not a system-wide install:
     6 import sys
     6 import sys
     7 sys.path.insert(0, "/home/isabelle-repository/repos/mercurial-www4/lib64/python2.5/site-packages")
     7 # using the hg installation provided by the system (AK, 3.3.2010)
       
     8 #sys.path.insert(0, "/home/isabelle-repository/repos/mercurial-www4/lib64/python2.5/site-packages")
       
     9 #sys.path.insert(0, "/usr/lib64/python2.5/site-packages")
       
    10 #sys.path.insert(0, "/home/isabelle-repository/repos/mercurial-1.3.1/lib64")
       
    11 #sys.path.insert(0, "/home/isabelle-repository/repos/testtool")
       
    12 
     8 
    13 
     9 # enable importing on demand to reduce startup time
    14 # enable importing on demand to reduce startup time
    10 from mercurial import demandimport; demandimport.enable()
    15 from mercurial import demandimport; demandimport.enable()
    11 
    16 
    12 # Uncomment to send python tracebacks to the browser if an error occurs:
    17 # Uncomment to send python tracebacks to the browser if an error occurs:
    18 # Note that this will cause your .hgrc files to be interpreted in
    23 # Note that this will cause your .hgrc files to be interpreted in
    19 # UTF-8 and all your repo files to be displayed using UTF-8.
    24 # UTF-8 and all your repo files to be displayed using UTF-8.
    20 #
    25 #
    21 import os
    26 import os
    22 os.environ["HGENCODING"] = "UTF-8"
    27 os.environ["HGENCODING"] = "UTF-8"
       
    28 os.environ["HGRCPATH"] = "/home/isabelle-repository/repos/hgrc"
    23 
    29 
    24 from mercurial.hgweb.hgwebdir_mod import hgwebdir
    30 from mercurial.hgweb.hgwebdir_mod import hgwebdir
    25 import mercurial.hgweb.wsgicgi as wsgicgi
    31 import mercurial.hgweb.wsgicgi as wsgicgi
    26 
    32 
    27 # The config file looks like this.  You can have paths to individual
    33 # The config file looks like this.  You can have paths to individual