-
Notifications
You must be signed in to change notification settings - Fork 1
/
install.py
58 lines (48 loc) · 1.28 KB
/
install.py
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# TODO:
# - [ ] Disk partitioning
# - [ ] User creation
# - [ ] Set up dotfiles directory and bare repository
# - [ ] Downloading and installing packages
# - [ ] Download yay
import os
import subprocess
def partition_disks():
"""
Function partitions disks for the fresh Arch Linux installation
"""
return None
def create_user():
"""
Function creates a user on Arch Linux
"""
return None
def install_packages(packages: list[str]) -> None:
"""
Function installs packages present in the packages list
"""
for package in packages:
try:
subprocess.call(["sudo", "pacman", "-S", "-q", "--noconfirm"], package)
# print()
except:
# error handling
def download_yay():
return None
def init_dotfiles():
repository_url = "https://github.com/qbibubi/.dotfiles.git"
home_path = os.path.expanduser("~")
subprocess.call(["git", "clone", "--bare"], repository_url, home_path)
# TODO: Finish writing dotfiles
subprocess.call(["echo", alias, ">"], shell=True)
def main():
packages = [
"git",
"archlinux-keyring",
"tmux",
"neovim",
"firefox-developer-edition"
]
partition_disks()
create_user()
install_packages(packages)
init_dotfiles()