comparison mercurial/hgweb/hgwebdir_mod.py @ 27046:37fcfe52c68c

hgweb: use absolute_import
author Yuya Nishihara <yuya@tcha.org>
date Sat, 31 Oct 2015 22:07:40 +0900
parents eac72c1e1e0d
children f97a0bcfd7a1
comparison
equal deleted inserted replaced
27045:eac72c1e1e0d 27046:37fcfe52c68c
4 # Copyright 2005, 2006 Matt Mackall <mpm@selenic.com> 4 # Copyright 2005, 2006 Matt Mackall <mpm@selenic.com>
5 # 5 #
6 # This software may be used and distributed according to the terms of the 6 # This software may be used and distributed according to the terms of the
7 # GNU General Public License version 2 or any later version. 7 # GNU General Public License version 2 or any later version.
8 8
9 import os, re, time 9 from __future__ import absolute_import
10 from mercurial.i18n import _ 10
11 from mercurial import hg, scmutil, util, templater 11 import os
12 from mercurial import ui as uimod 12 import re
13 from mercurial import error, encoding 13 import time
14 from common import ErrorResponse, get_mtime, staticfile, paritygen, ismember, \ 14
15 get_contact, HTTP_OK, HTTP_NOT_FOUND, HTTP_SERVER_ERROR 15 from ..i18n import _
16 import hgweb_mod 16
17 from request import wsgirequest 17 from .common import (
18 import webutil, wsgicgi 18 ErrorResponse,
19 HTTP_NOT_FOUND,
20 HTTP_OK,
21 HTTP_SERVER_ERROR,
22 get_contact,
23 get_mtime,
24 ismember,
25 paritygen,
26 staticfile,
27 )
28 from .request import wsgirequest
29
30 from .. import (
31 encoding,
32 error,
33 hg,
34 scmutil,
35 templater,
36 ui as uimod,
37 util,
38 )
39
40 from . import (
41 hgweb_mod,
42 webutil,
43 wsgicgi,
44 )
19 45
20 def cleannames(items): 46 def cleannames(items):
21 return [(util.pconvert(name).strip('/'), path) for name, path in items] 47 return [(util.pconvert(name).strip('/'), path) for name, path in items]
22 48
23 def findrepos(paths): 49 def findrepos(paths):