()
| 27 | return None |
| 28 | |
| 29 | def getGitBranchName(): |
| 30 | print( 'Retrieving git branch name' ) |
| 31 | process = subprocess.Popen( ['git', 'rev-parse', '--abbrev-ref', 'HEAD'], stdout=subprocess.PIPE ) |
| 32 | (output, err) = process.communicate() |
| 33 | exitCode = process.wait() |
| 34 | |
| 35 | if exitCode == 0: |
| 36 | output = output.decode() |
| 37 | branchName = output.replace( '\n', '' ) |
| 38 | return branchName |
| 39 | else: |
| 40 | return None |
| 41 | |
| 42 | branchName = getMercurialBranchName() |
| 43 |
no test coverage detected