(directory)
| 53 | |
| 54 | |
| 55 | def tfs_root(directory): |
| 56 | try: |
| 57 | tf_cmd = get_user_command('tf') or 'tf' |
| 58 | command = [tf_cmd, 'workfold', directory] |
| 59 | p = subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE, |
| 60 | shell=True, universal_newlines=False) |
| 61 | out, err = p.communicate() |
| 62 | m = re.search(r"^ \$\S+: (\S+)$", out, re.MULTILINE) |
| 63 | if m: |
| 64 | return {'root': m.group(1), 'name': 'tf', 'cmd': tf_cmd} |
| 65 | except: |
| 66 | return None |
| 67 | |
| 68 | |
| 69 | def get_vcs(directory): |
no test coverage detected
searching dependent graphs…