blob: 4099a02f06dc8017be51fe7941fc65ba7dd3ca2a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
#!/usr/bin/env bash
# Maintainer: Oskari Pirhonen <xxc3ncoredxx@gmail.com>
set -ex
install_versions=( "${@/#/python}" )
# Fix any pypy versions
install_versions=( "${install_versions[@]/#pythonpypy/pypy}" )
sudo apt-get install -y --no-install-recommends \
python-is-python3 \
python3-dev \
python3-venv \
"${install_versions[@]}" \
"${install_versions[@]/%/-dev}" \
"${install_versions[@]/%/-venv}"
for py in "$@"; do
if [[ "$py" != pypy* ]]; then
"python$py" -m venv ".venv-$py"
else
"$py" -m venv ".venv-$py"
fi
source ".venv-$py/bin/activate"
pip install --upgrade pip
deactivate
done
python -m venv .venv
source .venv/bin/activate
pip install --upgrade pip
deactivate
|