Mercurial > hg-stable
changeset 25980:38c585c2f8cc
subrepo: use absolute_import
author | Gregory Szorc <gregory.szorc@gmail.com> |
---|---|
date | Sat, 08 Aug 2015 20:03:58 -0700 |
parents | b723f05ec49b |
children | fa91c49a9b9f |
files | mercurial/subrepo.py |
diffstat | 1 files changed, 28 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/subrepo.py Sat Aug 08 20:01:40 2015 -0700 +++ b/mercurial/subrepo.py Sat Aug 08 20:03:58 2015 -0700 @@ -5,15 +5,34 @@ # This software may be used and distributed according to the terms of the # GNU General Public License version 2 or any later version. +from __future__ import absolute_import + import copy -import errno, os, re, posixpath, sys +import errno +import os +import posixpath +import re +import stat +import subprocess +import sys +import tarfile import xml.dom.minidom -import stat, subprocess, tarfile -from i18n import _ -import config, util, node, error, cmdutil, scmutil, match as matchmod -import phases -import pathutil -import exchange + + +from .i18n import _ +from . import ( + cmdutil, + config, + error, + exchange, + match as matchmod, + node, + pathutil, + phases, + scmutil, + util, +) + hg = None propertycache = util.propertycache @@ -328,7 +347,7 @@ # so we manually delay the circular imports to not break # scripts that don't use our demand-loading global hg - import hg as h + from . import hg as h hg = h pathutil.pathauditor(ctx.repo().root)(path) @@ -346,7 +365,7 @@ # so we manually delay the circular imports to not break # scripts that don't use our demand-loading global hg - import hg as h + from . import hg as h hg = h pathutil.pathauditor(ctx.repo().root)(path)