/
run_once_install-fedora-packages.sh.tmpl
133 lines (112 loc) · 4.01 KB
/
run_once_install-fedora-packages.sh.tmpl
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
#!/bin/sh
{{ if eq .chezmoi.os "linux" }}
{{ if eq .chezmoi.osRelease.id "fedora" }}
# Fedora-specific code
set -e # -e: exit on error
sudo dnf copr enable atim/starship -y
sudo dnf update -y
sudo dnf install -y \
flatpak \
git \
util-linux-user \
zsh \
ripgrep \
patch \
lm_sensors \
hddtemp \
nvme-cli \
neofetch \
ncdu \
rsync \
pwgen \
mc \
direnv \
htop \
alacritty \
jq \
dnf-plugins-core \
ffmpeg-free \
fzf \
starship \
distrobox \
neovim \
nodejs # nodejs needed for https://github.com/derekstride/tree-sitter-sql
sudo dnf copr enable vstanek/gnome-info-collect -y
sudo dnf install gnome-info-collect -y
flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
flatpak install -y flathub com.bitwarden.desktop
flatpak install -y flathub com.discordapp.Discord
flatpak install -y flathub com.microsoft.Teams
flatpak install -y flathub com.slack.Slack
flatpak install -y flathub com.spotify.Client
flatpak install -y flathub im.riot.Riot
flatpak install -y flathub net.cozic.joplin_desktop
flatpak install -y flathub org.chromium.Chromium
flatpak install -y flathub org.signal.Signal
flatpak install -y flathub org.telegram.desktop
flatpak install -y flathub org.videolan.VLC
flatpak install -y flathub com.github.eneshecan.WhatsAppForLinux
# https://github.com/stephane-klein/dotfiles/issues/67
sudo flatpak override --env=MOZ_ENABLE_WAYLAND=1
# Install Docker (see https://docs.docker.com/engine/install/fedora/)
# https://developer.fedoraproject.org/tools/docker/docker-installation.html
sudo dnf remove -y podman
sudo dnf config-manager -y --add-repo https://download.docker.com/linux/fedora/docker-ce.repo
sudo dnf install -y docker-ce docker-ce-cli containerd.io docker-compose-plugin iptables fuse-overlayfs docker-compose
# https://docs.docker.com/engine/install/linux-postinstall/
sudo groupadd docker && sudo gpasswd -a ${USER} docker && sudo systemctl restart docker
sudo systemctl enable docker
sudo dnf builddep -y python3
# neovim dependencies: ripgrep
# asdf python dependencies: patch and "dnf builddep python3"
chsh -s $(which zsh)
if ! [ -d ~/.oh-my-zsh ]; then
CHSH=no sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
fi
if ! [ -d ~/.oh-my-zsh/custom}/plugins/pnpm ]; then
mkdir -p ~/.oh-my-zsh/custom}/plugins/pnpm
git clone --depth=1 https://github.com/ntnyq/omz-plugin-pnpm.git ~/.oh-my-zsh/custom/plugins/pnpm
fi
# Install https://github.com/ryanoasis/nerd-fonts/tree/master/patched-fonts/Hack
if ! fc-list | grep "Hack Regular Nerd Font" &> /dev/null; then
(
cd ~/
git clone --filter=blob:none --sparse https://github.com/ryanoasis/nerd-fonts.git ~/nerd-fonts
cd nerd-fonts
git sparse-checkout add patched-fonts/Hack
./install.sh Hack
cd ..
rm -rf nerd-fonts
)
fi
# Install neovim dependencies
if ! [ -d ~/.local/share/nvim/site/pack/packer/start/packer.nvim ]; then
git clone --depth 1 https://github.com/wbthomason/packer.nvim\
~/.local/share/nvim/site/pack/packer/start/packer.nvim
fi
# Install Neovim package with Packer
PACKER_INSTALL_ONLY=1 nvim --headless -c 'autocmd User PackerComplete quitall' -c 'PackerSync'
if ! [ -d ~/.local/share-trial/nvim/site/pack/packer/start/packer.nvim ]; then
# Install neovim dependencies for nvim trial instance
git clone --depth 1 https://github.com/wbthomason/packer.nvim\
~/.local/share-trial/nvim/site/pack/packer/start/packer.nvim
fi
# Install asdf
if ! [ -d ~/.asdf ]; then
git -c advice.detachedHead=false clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch v0.10.2
fi
. $HOME/.asdf/asdf.sh
asdf update
asdf plugin add nodejs || true
asdf plugin add pnpm || true
asdf plugin add python || true
asdf plugin add yarn || true
asdf plugin add golang || true
(
cd ~/
asdf install
)
echo "Launch 'source ~/.zshrc' to reload zsh configuration"
echo "User added to docker group, then you need to restart session"
{{ end }}
{{ end }}