72 lines
1.8 KiB
Python
72 lines
1.8 KiB
Python
from decman import File, Module
|
|
from decman.plugins.aur import packages as aur_packages
|
|
from decman.plugins.pacman import packages as pacman_packages
|
|
|
|
|
|
class BaseModule(Module):
|
|
def __init__(self, user: str):
|
|
super().__init__("base")
|
|
self.user = user
|
|
|
|
def files(self) -> dict[str, File]:
|
|
return {
|
|
"/etc/pacman.conf": File(
|
|
source_file="./system/etc/pacman.conf",
|
|
),
|
|
"/etc/pacman.d/mirrorlist": File(
|
|
source_file="./system/etc/pacman.d/mirrorlist",
|
|
),
|
|
"/etc/sudoers.d/10-wheel": File(
|
|
source_file="./system/etc/sudoers.d/10-wheel",
|
|
permissions=0o440,
|
|
),
|
|
f"/home/{self.user}/.config/git/config": File(
|
|
source_file="./home/.config/git/config",
|
|
owner=self.user,
|
|
),
|
|
f"/home/{self.user}/.config/starship.toml": File(
|
|
source_file="./home/.config/starship.toml",
|
|
owner=self.user,
|
|
),
|
|
}
|
|
|
|
@pacman_packages
|
|
def pacman_packages(self) -> set[str]:
|
|
return {
|
|
"7zip",
|
|
"atuin",
|
|
"base-devel",
|
|
"base",
|
|
"bat",
|
|
"btop",
|
|
"chromium",
|
|
"curl",
|
|
"direnv",
|
|
"duf",
|
|
"dust",
|
|
"eza",
|
|
"fastfetch",
|
|
"fd",
|
|
"git-delta",
|
|
"git",
|
|
"jq",
|
|
"micro",
|
|
"ouch",
|
|
"procs",
|
|
"ripgrep",
|
|
"sd",
|
|
"starship",
|
|
"sudo",
|
|
"wget",
|
|
"yazi",
|
|
"yq",
|
|
"zoxide",
|
|
}
|
|
|
|
@aur_packages
|
|
def aur_packages(self) -> set[str]:
|
|
return {
|
|
"decman",
|
|
"gomi-bin",
|
|
}
|