-
Notifications
You must be signed in to change notification settings - Fork 0
/
arch-packages.sh
executable file
·271 lines (249 loc) · 7.91 KB
/
arch-packages.sh
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
#!/usr/bin/env bash
package_manager() {
pushd /tmp || return
git clone https://aur.archlinux.org/yay.git
cd yay || return
makepkg -is --noconfirm
rm -rf yay
popd || return
yay -Syu --noconfirm
}
core_pkgs() {
pkgs=(
bc
cmake
cronie # crontab
dmidecode # virt-manager
dnsmasq # virt-manager
docker
docker-compose
docker-scan # scan vulnerabilities
elixir
elixir-ls
erlang
fd
ffmpeg
firefox
flake8
fzf
gnupg
google-chrome
graphviz
htop
hunspell-en_us
inetutils # hostname
inotify-tools # used by elixir
intel-media-driver # required by Firefox
jq
lazygit
lf # cli file navigator
libvirt
lua-language-server
mpv
neofetch
nmap
nodejs-lts-hydrogen
noto-color-emoji-fontconfig # fix alacritty emoji
noto-fonts
noto-fonts-cjk
noto-fonts-emoji # fix alacritty emoji
npm
nvim
obs-studio # for video streaming and video recording
p7zip
pandoc
perl-file-mimeinfo # provides mimeopen and mimetype (see https://wiki.archlinux.org/title/default_applications#perl-file-mimeinfo)
pigz # docker
postgresql
python-pip
python-virtualenv
qemu # virt-manager
qemu-emulators-full # libvirt
ripgrep
rsync
rust
rust-analyzer
shellcheck
speech-dispatcher # required by firefox
stylua
tailwindcss-language-server
thunderbird
tmux
tree
ttf-jetbrains-mono-nerd
ttf-ms-fonts # Microsoft fonts
ttf-ubuntu-font-family
unzip
usbutils # lsusb
virt-manager
viu # preview images in the terminal
wireguard-tools
yamllint
yapf
yarn
yarr # rss browser reader
yq # jq but for yaml and toml
yt-dlp
zip
zk # zettelkasten cli tool
zsh-autosuggestions
zsh-syntax-highlighting
)
yay -S "${pkgs[@]}"
sudo usermod -a -G libvirt "$USER"
sudo systemctl enable libvirtd.service --now
sudo systemctl enable cronie.service --now
sudo usermod -a -G docker "$USER"
sudo systemctl enable docker.service --now
}
work_pkgs() {
pkgs=(
bloomrpc-bin # graphical grpc client
devcontainer-cli
google-cloud-cli # work related
google-cloud-cli-gke-gcloud-auth-plugin # work related
k9s # cli k8s frontend
kubectl
slack-desktop
teams-for-linux-bin
)
yay -S "${pkgs[@]}"
}
gnome_pkgs() {
pkgs=(
gnome-shell-extension-dash-to-dock
gpaste # clipboard manager, gnome shell extension
obsidian-icon-theme
xclip
)
yay -S "${pkgs[@]}"
# Preferable way to enable ssh-agent (it depricates gnome-keyring-daemon).
# https://wiki.archlinux.org/title/GNOME/Keyring#SSH_keys
systemctl --user enable gcr-ssh-agent.service --now
}
sway_pkgs() {
pkgs=(
autotiling-rs # spiral tiling sway/i3
bemenu # wayland menu / runner
blueman # bluetooth manager
brightnessctl # part of sway wm
cliphist # persistent clipboard history
fontconfig-ubuntu # alternative to fontconfig
gnome-keyring # required by auto unlock gpg, ssh keys
greetd # greeter manager
greetd-tuigreet # required by greetd
grim # for color-pick
gtk-engine-murrine # required for arc theme
gvfs-mtp # android mtp
imagemagick # required by grim
imv # image viewer
libsecret # required by auto unlock gpg, ssh keys
mako # notification service
man-pages # posix pages
mtpfs # android mtp
nwg-look # change theme style for gtk, kde and xwayland
otf-font-awesome # required by waybar
pipewire-pulse
pulsemixer # sound cli interface
python-i3ipc # sway rpc
qt5-wayland
qt6-wayland
seahorse # required by auto unlock gpg, ssh keys
slurp # select regeion on Wayland
swaybg # set background from terminal
swayidle # see sway/config
swaylock # see sway/config
thunar # gui file manager
ttf-roboto # required by waybar
ttf-roboto-mono # required by waybar
ttf-ubuntu-font-family
ttf-ubuntu-mono-nerd
ttf-ubuntu-nerd
waybar # part of sway wm
wev-git # transcribe keyboard and mouth events
wf-recorder # audio and screen recording for Wayland
wl-clipboard
wlsunset # day/night gamma adjustments
xdg-desktop-portal
xdg-desktop-portal-wlr # (powered by wireplumber) required for screen sharing on Wayland
xdg-utils # xdg-open
xfce4-settings # as nwg-look is in use, we still need the package since it still has useful gnome dependencies.
xorg-server-xvfb # required by cypress javascript library to run a virtual desktop
xorg-xwayland
)
yay -S "${pkgs[@]}"
systemctl --user enable wireplumber --now # audio
systemctl --user enable pipewire-pulse.service --now # bluetooth
# Auto open on login ssh and gpg keys.
sudo perl -i -p -e 's/components=".*"/components="pkcs11,secrets,ssh"/;' \
/usr/lib/systemd/user/gnome-keyring-daemon.service
systemctl --user enable gcr-ssh-agent.service
systemctl --user enable gnome-keyring-daemon.service --now
f="/etc/pam.d/login"
s="auth optional pam_gnome_keyring.so"
grep -q "$s" "$f" || (echo "$s" | sudo tee -a "$f")
s="session optional pam_gnome_keyring.so auto_start"
grep -q "$s" "$f" || (echo "$s" | sudo tee -a "$f")
unset f s
## Login Manager.
sudo perl -i -p -e 's/command = ".*"/command = "tuigreet --cmd sway"/;' \
/etc/greetd/config.toml || true
sudo chmod -R go+r /etc/greetd/
sudo usermod -a -G greetd "$USER"
sudo systemctl enable greetd.service
# Disable hibernation on lid closed when logout.
# sudo echo "HandleLidSwitchExternalPower=ignore" >> /etc/systemd/logind.conf
}
wm_pkgs() {
[ -x "$(command -v gnome-shell)" ] && gnome_pkgs
[ -n "$SWAYSOCK" ] && sway_pkgs
}
optional_pkgs() {
pkgs=(
# anki
audacity
biber # required by homepage
discord
drawio-desktop-bin
gimp # gimp-devel is a good alternative supported hidpi and requires compilation
hugo # homepage
inkscape
libreoffice-fresh
libreoffice-fresh-en-gb
libreoffice-fresh-uk
qbittorrent
telegram-desktop
texlive-bibtexextra # homepage
texlive-fontsextra # homepage
texlive-latexextra # homepage
wireshark-qt
zapzap # whatsapp clone
)
yay -S "${pkgs[@]}"
sudo usermod -a -G wireshark "$USER"
}
node_pkgs() {
sudo -H npm install -g n vscode-css-languageserver-bin vscode-langservers-extracted typescript typescript-language-server eslint prettier pyright
}
go_pkgs() {
go install golang.org/x/tools/gopls@latest
go install golang.org/x/tools/cmd/goimports@latest
go install github.com/segmentio/golines@latest
go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
go install github.com/go-delve/delve/cmd/dlv@latest
go install github.com/illia-danko/fdir@latest
}
misc_pkgs() {
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
git clone --depth=1 https://github.com/zsh-users/zsh-syntax-highlighting ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
git clone --depth=1 https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
}
# Install packages.
package_manager
core_pkgs
# wm_pkgs
node_pkgs
go_pkgs
# work_pkgs
# optional_pkgs
misc_pkgs