Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

executable file 32 lines (26 sloc) 0.737 kb
#!/usr/bin/env python
import os
import sys
from packager import generate_script
here = os.path.dirname(os.path.abspath(__file__))
file_name = os.path.join(here, 'get-pip.py')
entry = """
import pip
pip.bootstrap()
"""
def main():
sys.stdout.write("Creating pip bootstrapper...")
script = generate_script(entry, ['pip'])
f = open(file_name, 'w')
try:
f.write(script)
finally:
f.close()
sys.stdout.write('done.\n')
if hasattr(os, 'chmod'):
oldmode = os.stat(file_name).st_mode & 07777
newmode = (oldmode | 0555) & 07777
os.chmod(file_name, newmode)
sys.stdout.write('Made resulting file %s executable.\n\n' % file_name)
if __name__ == '__main__':
main()
Jump to Line
Something went wrong with that request. Please try again.