srchub

srchub Commit Details


Date:2015-07-12 18:31:21 (9 years 5 months ago)
Author:Natalie Adams
Branch:master
Commit:0d798632de0986cb056fec0fb58e2b2cd01422fd
Parents: 2a020ba09212e24f232716d92e392ef19684b7b8
Message:Allow viewing of hg repo if direct navigation

Changes:

File differences

indefero/scripts/hgweb.cgi
66
77
88
9
910
1011
1112
......
2021
2122
2223
23
24
2425
2526
2627
# Path to repo or hgweb config to serve (see 'hg help hgweb')
# config = "/path/to/repo/or/config"
import os
import sys
config = "/home/www/indefero/scripts/hgweb.config"
# Uncomment and adjust if Mercurial is not installed system-wide
application = hgwebdir(config)
newrepos = []
for repo in application.repos:
if not os.path.isfile(repo[1] + "/.hide"):
if not os.path.isfile(repo[1] + "/.hide") or repo[0] in os.environ["REQUEST_URI"]:
newrepos.append(repo)
application.repos = newrepos
wsgicgi.launch(application)

Archive Download the corresponding diff file

Branches

Number of commits:
Page rendered in 0.05327s using 14 queries.