Plugins/VcsPlugins/vcsSubversion/SvnUtilities.py

changeset 0
de9c2efb9d02
child 13
1af94a91f439
equal deleted inserted replaced
-1:000000000000 0:de9c2efb9d02
1 # -*- coding: utf-8 -*-
2
3 # Copyright (c) 2006 - 2009 Detlev Offenbach <detlev@die-offenbachs.de>
4 #
5
6 """
7 Module implementing some common utility functions for the subversion package.
8 """
9
10 import sys
11 import os
12
13 from PyQt4.QtCore import QDateTime, Qt
14
15 import Utilities
16
17 def getServersPath():
18 """
19 Public method to get the filename of the servers file.
20
21 @return filename of the servers file (string)
22 """
23 if Utilities.isWindowsPlatform():
24 appdata = os.environ["APPDATA"]
25 return os.path.join(appdata, "Subversion", "servers")
26 else:
27 homedir = Utilities.getHomeDir()
28 return os.path.join(homedir, ".subversion", "servers")
29
30 def getConfigPath():
31 """
32 Public method to get the filename of the config file.
33
34 @return filename of the config file (string)
35 """
36 if Utilities.isWindowsPlatform():
37 appdata = os.environ["APPDATA"]
38 return os.path.join(appdata, "Subversion", "config")
39 else:
40 homedir = Utilities.getHomeDir()
41 return os.path.join(homedir, ".subversion", "config")

eric ide

mercurial