(url, file)
| 145 | sys.exit(process.returncode) |
| 146 | |
| 147 | def fetch(url, file): |
| 148 | if not os.path.exists(file): |
| 149 | print('Downloading', url, flush=True) |
| 150 | data = urllib.request.urlopen(url).read() |
| 151 | if os.path.dirname(file): |
| 152 | makedirs(os.path.dirname(file)) |
| 153 | with open(file, 'wb') as f: |
| 154 | f.write(data) |
| 155 | |
| 156 | def fetch_maven(group, name, version, classifier=None, repo='https://repo1.maven.org/maven2'): |
| 157 | path = '/'.join([group.replace('.', '/'), name, version, name + '-' + version + ('-' + classifier if classifier else '') + '.jar']) |
no test coverage detected