Add logic to install with get-pip.py
on python2
This commit is contained in:
parent
a2f5542ed8
commit
fd0e55ab60
|
@ -2,7 +2,7 @@
|
|||
################################################################################
|
||||
#
|
||||
# Rattail -- Retail Software Framework
|
||||
# Copyright © 2010-2021 Lance Edgar
|
||||
# Copyright © 2010-2022 Lance Edgar
|
||||
#
|
||||
# This file is part of Rattail.
|
||||
#
|
||||
|
@ -149,7 +149,10 @@ def install_pip(c, method=None,
|
|||
apt.install(c, package, warn=True)
|
||||
|
||||
elif method == 'get-pip':
|
||||
c.sudo('wget -O get-pip.py https://bootstrap.pypa.io/get-pip.py')
|
||||
url = 'https://bootstrap.pypa.io/get-pip.py'
|
||||
if not python3:
|
||||
url = 'https://bootstrap.pypa.io/pip/2.7/get-pip.py'
|
||||
c.sudo('wget -O get-pip.py {}'.format(url))
|
||||
python = 'python3' if python3 else 'python2'
|
||||
c.sudo('{} get-pip.py'.format(python))
|
||||
c.sudo('rm get-pip.py')
|
||||
|
|
Loading…
Reference in a new issue