Plugins/VcsPlugins/vcsMercurial/HgUtilities.py

Thu, 02 May 2013 18:09:11 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Thu, 02 May 2013 18:09:11 +0200
changeset 2642
c9f965bd21d2
parent 2302
f29e9405c851
child 2525
8b507a9a2d40
child 2816
05aab5164d64
child 3163
9f50365a0870
permissions
-rw-r--r--

Fixed an issue in the Mercurial log browser dialog causing the 'Copy Changeset' button not being updated correctly.

# -*- coding: utf-8 -*-

# Copyright (c) 2010 - 2013 Detlev Offenbach <detlev@die-offenbachs.de>
#

"""
Module implementing some common utility functions for the Mercurial package.
"""

import os

import Utilities


def getConfigPath():
    """
    Public method to get the filename of the config file.
    
    @return filename of the config file (string)
    """
    if Utilities.isWindowsPlatform():
        userprofile = os.environ["USERPROFILE"]
        return os.path.join(userprofile, "Mercurial.ini")
    else:
        homedir = Utilities.getHomeDir()
        return os.path.join(homedir, ".hgrc")

eric ide

mercurial