Skip to content
This repository has been archived by the owner on Feb 18, 2019. It is now read-only.

Commit

Permalink
Default to ~/.moz-commitbuilder-cache for shellCacheDir
Browse files Browse the repository at this point in the history
  • Loading branch information
mnoorenberghe committed Feb 15, 2013
1 parent ad15048 commit 10e95a9
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions mozcommitbuilder/builder.py
Expand Up @@ -77,14 +77,22 @@
progVersion="0.4.10"

class Builder():
def __init__(self, makeCommand=["make","-f","client.mk","build"] , shellCacheDir=os.path.join(os.path.expanduser("~"),
"moz-commitbuilder-cache"), cores=1, repoURL="http://hg.mozilla.org/mozilla-central",clean=False,
def __init__(self, makeCommand=["make","-f","client.mk","build"] , shellCacheDir=None,
cores=1, repoURL="http://hg.mozilla.org/mozilla-central",clean=False,
mozconf=None, tryhost=None, tryport=None, remote=False, tryPusher=False,
testBinaries=False, deleteTrunk=False):

#Set variables that we need
self.makeCommand = makeCommand

# Default to ~/.moz-commitbuilder-cache if ~/moz-commitbuilder-cache doesn't exist.
if not shellCacheDir:
shellCacheDir = os.path.join(os.path.expanduser("~"), "moz-commitbuilder-cache")
if not os.path.isdir(shellCacheDir):
shellCacheDir = os.path.join(os.path.expanduser("~"), ".moz-commitbuilder-cache")

self.shellCacheDir = shellCacheDir

self.testDir = os.path.join(shellCacheDir,"tests")
self.cores = cores
self.repoURL = repoURL
Expand Down

0 comments on commit 10e95a9

Please sign in to comment.