Show More
@@ -161,6 +161,15 b' def has_p4():' | |||||
161 | return matchoutput('p4 -V', r'Rev\. P4/') and matchoutput('p4d -V', r'Rev\. P4D/') |
|
161 | return matchoutput('p4 -V', r'Rev\. P4/') and matchoutput('p4d -V', r'Rev\. P4D/') | |
162 |
|
162 | |||
163 | def has_symlink(): |
|
163 | def has_symlink(): | |
|
164 | if not hasattr(os, "symlink"): | |||
|
165 | return False | |||
|
166 | name = tempfile.mktemp(dir=".", prefix='hg-checklink-') | |||
|
167 | try: | |||
|
168 | os.symlink(".", name) | |||
|
169 | os.unlink(name) | |||
|
170 | return True | |||
|
171 | except (OSError, AttributeError): | |||
|
172 | return False | |||
164 | return hasattr(os, "symlink") # FIXME: should also check file system and os |
|
173 | return hasattr(os, "symlink") # FIXME: should also check file system and os | |
165 |
|
174 | |||
166 | def has_tla(): |
|
175 | def has_tla(): |
General Comments 0
You need to be logged in to leave comments.
Login now