Skip to content

Commit

Permalink
TIMOB-4758 check for Windows env an append .cmd to git command in bui…
Browse files Browse the repository at this point in the history
…ld scripts
  • Loading branch information
dizzymonkey committed Jul 27, 2011
1 parent ffa46ec commit 79f2d45
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion SConstruct
Expand Up @@ -27,7 +27,11 @@ elif ARGUMENTS.get('PRODUCT_VERSION', 0):
# get the githash for the build so we can always pull this build from a specific
# commit. We're getting it here so we can pass it to android's ant build
# in order to get it into build.properties
p = subprocess.Popen(["git","show","--abbrev-commit"],stderr=subprocess.PIPE, stdout=subprocess.PIPE)
gitCmd = "git"
if platform.system() == "Windows":
gitCmd += ".cmd"

p = subprocess.Popen([gitCmd,"show","--abbrev-commit"],stderr=subprocess.PIPE, stdout=subprocess.PIPE)
githash = p.communicate()[0][8:].split('\n')[0]

#
Expand Down
6 changes: 5 additions & 1 deletion site_scons/package.py
Expand Up @@ -23,7 +23,11 @@

# get the githash for the build so we can always pull this build from a specific
# commit
p = subprocess.Popen(["git","show","--abbrev-commit"],stderr=subprocess.PIPE, stdout=subprocess.PIPE)
gitCmd = "git"
if platform.system() == "Windows":
gitCmd += ".cmd"

p = subprocess.Popen([gitCmd,"show","--abbrev-commit"],stderr=subprocess.PIPE, stdout=subprocess.PIPE)
githash = p.communicate()[0][7:].split('\n')[0].strip()

ignoreExtensions = ['.pbxuser','.perspectivev3','.pyc']
Expand Down

0 comments on commit 79f2d45

Please sign in to comment.