bbb192ffd5
- 新增包:starship, atuin, direnv, xh, yq, sd, zellij - 重写 .zshrc:Starship 提示符、Atuin 历史搜索、fzf 键绑定、 增强别名(eza --icons, ll, la, lt)、shell 选项、WSL 剪贴板 - 新增 starship.toml 配置 - 优化 git config:SSL 限定到内网地址、pull.rebase、 push.autoSetupRemote、rerere、delta line-numbers
70 lines
1.7 KiB
Python
70 lines
1.7 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):
|
|
return {
|
|
"/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 {
|
|
"atuin",
|
|
"base-devel",
|
|
"base",
|
|
"bat",
|
|
"btop",
|
|
"curl",
|
|
"direnv",
|
|
"duf",
|
|
"dust",
|
|
"eza",
|
|
"fastfetch",
|
|
"fd",
|
|
"git-delta",
|
|
"git",
|
|
"jq",
|
|
"micro",
|
|
"procs",
|
|
"ripgrep",
|
|
"sd",
|
|
"starship",
|
|
"sudo",
|
|
"tealdeer",
|
|
"trash-cli",
|
|
"vim",
|
|
"wget",
|
|
"xh",
|
|
"yazi",
|
|
"yq",
|
|
"zoxide",
|
|
}
|
|
|
|
@aur_packages
|
|
def aur_packages(self) -> set[str]:
|
|
return {
|
|
"decman",
|
|
"yay-bin",
|
|
}
|