()
| 181 | |
| 182 | |
| 183 | def main(): |
| 184 | tmpdir = None |
| 185 | try: |
| 186 | # Create a temporary working directory |
| 187 | tmpdir = tempfile.mkdtemp() |
| 188 | |
| 189 | # Unpack the zipfile into the temporary directory |
| 190 | pip_zip = os.path.join(tmpdir, "pip.zip") |
| 191 | with open(pip_zip, "wb") as fp: |
| 192 | fp.write(b85decode(DATA.replace(b"\n", b""))) |
| 193 | |
| 194 | # Add the zipfile to sys.path so that we can import it |
| 195 | sys.path.insert(0, pip_zip) |
| 196 | |
| 197 | # Run the bootstrap |
| 198 | bootstrap(tmpdir=tmpdir) |
| 199 | finally: |
| 200 | # Clean up our temporary working directory |
| 201 | if tmpdir: |
| 202 | shutil.rmtree(tmpdir, ignore_errors=True) |
| 203 | |
| 204 | |
| 205 | DATA = b""" |
no test coverage detected