diff options
author | Mickaël Salaün <mic@digikod.net> | 2012-09-30 00:37:55 +0200 |
---|---|---|
committer | Mickaël Salaün <mic@digikod.net> | 2012-10-10 08:30:15 +0200 |
commit | 2f6ab7f5b8f21b2dbfe9ae102674bd1694e94f03 (patch) | |
tree | 040f9045751d83902ea8c479304fdfa2a0061a54 /git_command.py | |
parent | 3a6cd4200e42fbb5a21b3fb8d3c9738c0320cc63 (diff) | |
download | git-repo-2f6ab7f5b8f21b2dbfe9ae102674bd1694e94f03.tar.gz |
Rename "dir" variables
The variable name "dir" conflicts with the name of a Python built-in
function: http://docs.python.org/library/functions.html#dir
Change-Id: I850f3ec8df7563dc85e21f2876fe5e6550ca2d8f
Diffstat (limited to 'git_command.py')
-rw-r--r-- | git_command.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/git_command.py b/git_command.py index 5988cc28..82709b91 100644 --- a/git_command.py +++ b/git_command.py | |||
@@ -37,11 +37,11 @@ def ssh_sock(create=True): | |||
37 | if _ssh_sock_path is None: | 37 | if _ssh_sock_path is None: |
38 | if not create: | 38 | if not create: |
39 | return None | 39 | return None |
40 | dir = '/tmp' | 40 | tmp_dir = '/tmp' |
41 | if not os.path.exists(dir): | 41 | if not os.path.exists(tmp_dir): |
42 | dir = tempfile.gettempdir() | 42 | tmp_dir = tempfile.gettempdir() |
43 | _ssh_sock_path = os.path.join( | 43 | _ssh_sock_path = os.path.join( |
44 | tempfile.mkdtemp('', 'ssh-', dir), | 44 | tempfile.mkdtemp('', 'ssh-', tmp_dir), |
45 | 'master-%r@%h:%p') | 45 | 'master-%r@%h:%p') |
46 | return _ssh_sock_path | 46 | return _ssh_sock_path |
47 | 47 | ||