-
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathinstall_pip_pkgs.py
More file actions
executable file
·44 lines (34 loc) · 848 Bytes
/
install_pip_pkgs.py
File metadata and controls
executable file
·44 lines (34 loc) · 848 Bytes
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
33
34
35
36
37
38
39
40
41
42
43
44
#!/usr/bin/env python3
"""
Script that installs Python packages from PyPI.
Takes in the image distribution as the first argument.
"""
import subprocess
import sys
DISTRO = sys.argv[1]
def install(packages=[]):
"""Installer for pip packages
Args:
packages (list(str)): List of package names
"""
if len(packages) > 0:
subprocess.check_call(["pip3", "install", "--break-system-packages", " ".join(packages)])
# Shared packages across distributions
shared_packages = []
# Packages specific to distribution
pip_packages = {
"rstudio": shared_packages + [],
"rstudio-local": shared_packages
+ [
"pre-commit",
],
"gcc13": [],
"gcc14": [],
"atlas": [],
"valgrind": [],
"intel": [],
"nosuggests": [],
"mkl": [],
}
# Install packages
install(pip_packages[DISTRO])