Skip to content

Commit 4d7567b

Browse files
Another python2 fix
1 parent 2789dab commit 4d7567b

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

.github/workflows/test.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,14 +43,17 @@ jobs:
4343
with:
4444
python-version: ${{ matrix.python-version }}
4545

46-
- name: Install Python 2.7 manually
46+
- name: Install Python 2.7 and set as default
4747
if: matrix.python-version == '2.7'
4848
run: |
4949
sudo apt-get update
50-
sudo apt-get install -y python2.7 python2.7-dev python2.7-distutils curl
50+
sudo apt-get install -y python2 curl
51+
sudo update-alternatives --install /usr/bin/python python /usr/bin/python2 1
52+
sudo update-alternatives --install /usr/bin/pip pip /usr/bin/pip2 1
5153
curl https://bootstrap.pypa.io/pip/2.7/get-pip.py --output get-pip.py
52-
sudo python2.7 get-pip.py
53-
python2.7 --version
54+
sudo python get-pip.py
55+
python --version
56+
pip --version
5457
5558
- name: Install dependencies
5659
run: |

0 commit comments

Comments
 (0)