mirror of
https://github.com/Derisis13/dotfiles.git
synced 2025-12-06 19:32:50 +01:00
feat(fedora.sh): created installer script
fix(grub): updated instructions to avoid overwriting grub config feat(btop): minor config changes
This commit is contained in:
48
README.md
48
README.md
@@ -1,30 +1,34 @@
|
||||
# HA5PLS's fedora install documentation
|
||||
- partitioning: differs every time
|
||||
- dnf: `cat ./dnf_packages.list | xargs sudo dnf install` Automatic generation of this file is TODO. Note that these are my packages, filter them for your personal needs. Some may be dependencies of other tools (eg. mostly for nvim and LSPs) (in 41 you need to use dnf4 explicitly: `dnf4 history userinstalled > dnf_packages.list`)
|
||||
- packages: todo barusu + base system + repo carry
|
||||
- alacritty: .config/alacritty/alacritty.toml + fira_code_mono_nerd_font installed (todo: script)
|
||||
- serif font: install google-roboto-fonts (used in gtk, qt, waybar)
|
||||
- zsh: $ZDOTDIR set in /etc/zshenv + omz install (todo:script) + .config/zsh + install fzf-tab plugin (git clone https://github.com/Aloxaf/fzf-tab ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/fzf-tab, needs sqlite as dependency) + for some reason $XDG_STATE_HOME/zsh needs to be created manually
|
||||
- hypr*: .config/hypr, install hyprlock, hyprsunset, hypridle,
|
||||
- hyprpaper: .config/hypr + download from [here](https://www.flickr.com/photos/nasahqphoto/5914101671/in/photostream/) to .local/wallpapers (also used for grub & sddm & hyprlock)
|
||||
- waybar: .config/waybar + install fontawesome4-fonts (for icons)
|
||||
- rofi: .config/rofi + extract neccessary parts from https://github.com/adi1090x/rofi install script
|
||||
- rofi-qalc: needs rofi-wayland-1.7.5+wayland2-3.fc40.x86_64 (find it in downloads or fedora build system) until ABI is fixed, rofi-devel, then compile this by hand: https://github.com/svenstaro/rofi-calc
|
||||
- sddm: dependency: `qt6-qtquickcontrols2 qt6-qtsvg`, copy sddm/sddm.conf -> /etc/sddm.conf & sddm/themes/catppuccin-macchiato -> /usr/share/sddm/themes/ then `# systemctl set-default graphical.target`
|
||||
- nvim: .config/nvim + alacritty done + deps: clang (gcc-c++), unzip, npm, ripgrep, go, then proceed with nvchad init
|
||||
- swaync: .config/swaync
|
||||
- gtk: .config/gtk-*, `dconf load /org/gtk/gtk4 < ./dconf-export/gtk4.dconf`
|
||||
- MPV: $XDG_CONFIG_HOME/mpv/
|
||||
- QT5: .config/qt6ct/, xsettingsd/
|
||||
To automatically setup the system, use the script `fedora.sh`, or run trough the manual setup.
|
||||
<details>
|
||||
<summary>Manual steps (this is what the script does)</summary>
|
||||
- partitioning: differs every time, done at install
|
||||
- dnf: `cat ./dnf_packages.list | xargs sudo dnf install` Note that these are my packages, filter them for your personal needs. Some may be dependencies of other tools (eg. mostly for nvim and LSPs) (to generate, use `dnf repoquery --userinstalled > dnf_packages.list`)
|
||||
- Flathub: `flatpak remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo`
|
||||
- kitty: `.config/kitty` + `fira_code_mono_nerd_font` installed
|
||||
- serif font: install `google-roboto-fonts` (used in gtk, qt, waybar)
|
||||
- zsh: `\$ZDOTDIR` set in `/etc/zshenv` + omz install (`sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" && mv ~/.oh-my-zsh ~/.local/share/oh-my-zsh && mkdir -p ~/.local/state/zsh/`) + `.config/zsh` + install fzf-tab plugin (git clone https://github.com/Aloxaf/fzf-tab ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/fzf-tab/, needs sqlite as dependency) + for some reason `$XDG_STATE_HOME/zsh` needs to be created manually
|
||||
- hypr*: `.config/hypr,` install `hyprlock`, `hyprsunset`, `hypridle`,
|
||||
- hyprpaper: `.config/hypr` + download from [here](https://www.flickr.com/photos/nasahqphoto/5914101671/in/photostream/) by `curl -o .local/share/backgrounds/eKxlw8.jpg -fsSL "https://live.staticflickr.com/5077/5914101671_d80c6591e8_k.jpg` (also used for grub & sddm & hyprlock)
|
||||
- waybar: `.config/waybar` + install `fontawesome4-fonts` (for icons)
|
||||
- rofi: `.config/rofi`
|
||||
- rofi-qalc: needs `rofi-wayland-1.7.5+wayland2-3.fc40.x86_64` (find it in downloads or fedora build system) until ABI is fixed, rofi-devel, then compile this by hand: https://github.com/svenstaro/rofi-calc
|
||||
- sddm: dependency: `qt6-qtquickcontrols2 qt6-qtsvg`, copy `sddm/sddm.conf` -> `/etc/sddm.conf` & `sddm/themes/catppuccin-macchiato` -> `/usr/share/sddm/themes/` then `# systemctl set-default graphical.target`
|
||||
- nvim: `.config/nvim` + kitty done + deps: clang (gcc-c++), unzip, npm, ripgrep, go, then proceed with nvchad init
|
||||
- swaync: `.config/swaync`
|
||||
- gtk: `.config/gtk-*`, `dconf load /org/gtk/gtk4 < ./dconf-export/gtk4.dconf`
|
||||
- MPV: `$XDG_CONFIG_HOME/mpv/`
|
||||
- QT5: `.config/qt6ct/`, `xsettingsd/`
|
||||
- kdeconnect: `# firewall-cmd --permanent --add-service=kdeconnect` + needs kdeconnectd restart to work
|
||||
- plymouth: copy plymouth/themes/fedora-mac-style -> /usr/share/plymouth/themes/ + install plymouth-plugin-two-step + (`plymouth-set-default-theme -l` -> if this displays the theme, installation can begin: `sudo plymouth-set-default-theme -R fedora-mac-style && sudo dracut --regenerate-all -f`)
|
||||
- grub: copy grub/grub -> /etc/default/grub & grub/themes -> /boot/themes then `grub2-mkconfig -o /boot/grub2/grub.cfg` To change font, you need grub2-tools-extra (for grub2-mkfont) and use it like `grub2-mkfont -o grub/themes/catppuccin-macchiato/font.pf2 -s 24 /usr/share/fonts/<family>/<specimen>.ttf` (after this you have to copy the configs again and regenerate the boot image)
|
||||
- udev: /etc/udev/rules.d/ (for setting driver permissions)
|
||||
- selinux: /etc/selinux/config to stay permissive (why even bother with selinux?)
|
||||
- plymouth: copy `plymouth/themes/fedora-mac-style` -> `/usr/share/plymouth/themes/` + install `plymouth-plugin-two-step` + (`plymouth-set-default-theme -l` -> if this displays the theme, installation can begin: `sudo plymouth-set-default-theme -R fedora-mac-style && sudo dracut --regenerate-all -f`)
|
||||
- grub: add line `GRUB_THEME=/boot/themes/catppuccin-macchiato-grub-theme/theme.txt` to `/etc/default/grub` and copy `grub/themes` -> `/boot/themes` then `grub2-mkconfig -o /boot/grub2/grub.cfg` To change font, you need `grub2-tools-extra` (for grub2-mkfont) and use it like `grub2-mkfont -o grub/themes/catppuccin-macchiato/font.pf2 -s 24 /usr/share/fonts/<family>/<specimen>.ttf` (after this you have to copy the configs again and regenerate the boot image)
|
||||
- udev: `/etc/udev/rules.d/` (for setting driver permissions)
|
||||
- selinux: `/etc/selinux/config` to stay permissive (why even bother with selinux?)
|
||||
- firefox(librewolf btw): do your own profile, install [catpuccin theme](https://github.com/catppuccin/firefox) and [darkreader](https://darkreader.org/)
|
||||
- gnome tooling (file picker, keyring, etc): dconf load `/org/gnome/desktop/ < ./dconf-export/gnome-desktop.dconf`
|
||||
- gnome tooling (file picker, keyring, etc): `dconf load /org/gnome/desktop/ < ./dconf-export/gnome-desktop.dconf`
|
||||
- nautilus (file manager): gtk set up, then `dconf load /org/gnome/nautilus < ./dconf-export/nautilus.dconf`
|
||||
- gedit (gui text editor): gtk set up, then `dconf load /org/gnome/gedit < ./dconf-export/gedit.dconf`
|
||||
</details>
|
||||
|
||||
# Showcase
|
||||
<br>
|
||||
|
||||
@@ -101,7 +101,7 @@ cpu_graph_upper = "Auto"
|
||||
cpu_graph_lower = "Auto"
|
||||
|
||||
#* If gpu info should be shown in the cpu box. Available values = "Auto", "On" and "Off".
|
||||
show_gpu_info = "Auto"
|
||||
show_gpu_info = "On"
|
||||
|
||||
#* Toggles if the lower CPU graph should be inverted.
|
||||
cpu_invert_lower = True
|
||||
@@ -187,7 +187,7 @@ disk_free_priv = False
|
||||
show_io_stat = True
|
||||
|
||||
#* Toggles io mode for disks, showing big graphs for disk read/write speeds.
|
||||
io_mode = False
|
||||
io_mode = True
|
||||
|
||||
#* Set to True to show combined read/write io graphs in io mode.
|
||||
io_graph_combined = False
|
||||
|
||||
103
fedora.sh
Normal file
103
fedora.sh
Normal file
@@ -0,0 +1,103 @@
|
||||
#!/bin/sh
|
||||
|
||||
replace_config_line () {
|
||||
file="$1"
|
||||
setting="$2"
|
||||
value="$3"
|
||||
if grep -Eq "^${setting}=" "$file"; then
|
||||
sed -e "s/^${setting}=.*$/${setting}=${value}/" < "$file" | sudo tee "$file"
|
||||
else
|
||||
printf "%s=%s\n" "${setting}" "${value}" | sudo tee -a "$file"
|
||||
fi
|
||||
}
|
||||
|
||||
replace_config_line "/etc/dnf/dnf.conf" "installonly_limit" "3"
|
||||
replace_config_line "/etc/dnf/dnf.conf" "best" "False"
|
||||
replace_config_line "/etc/dnf/dnf.conf" "skip_unavailable" "True"
|
||||
replace_config_line "/etc/dnf/dnf.conf" "fastestmirror" "True"
|
||||
replace_config_line "/etc/dnf/dnf.conf" "defaultyes" "True"
|
||||
replace_config_line "/etc/dnf/dnf.conf" "keepcache" "True"
|
||||
replace_config_line "/etc/dnf/dnf.conf" "max_parallel_downloads" "5"
|
||||
|
||||
ensure_installed () {
|
||||
for dep in !*; do
|
||||
dnf list --installed "$dep" 2>&1 | grep -q "$dep" || sudo dnf install "$dep" --assumeyes --allowerasing
|
||||
done
|
||||
}
|
||||
|
||||
# Enable extra repos
|
||||
sudo dnf update
|
||||
sudo dnf copr enable solopasha/hyprland
|
||||
sudo dnf copr enable tofik/sway
|
||||
sudo dnf install https://mirrors.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm
|
||||
|
||||
# Edit then install packages
|
||||
vi ./dnf_packages.list
|
||||
cat ./dnf_packages.list | xargs dnf install --assumeyes --skip-missing
|
||||
|
||||
# disable selinux
|
||||
replace_config_line "/etc/selinux/config" "SELINUX" "disabled"
|
||||
printf "You'll need to reboot to have selinux disabled\n"
|
||||
|
||||
# set up ZSH
|
||||
ensure_installed zsh fzf sqlite3
|
||||
replace_config_line '/etc/zshenv' 'export ZDOTDIR' '${HOME}/.config/zsh'
|
||||
mkdir -p ~/.local/state/zsh/
|
||||
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
|
||||
mv ~/.oh-my-zsh ~/.local/share/oh-my-zsh/ # TODO: figure out how to contol install location of script above. Maybe reboot/relog after xgd_user_dirs is installed?
|
||||
git clone https://github.com/Aloxaf/fzf-tab ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}
|
||||
curl -O -fsSL https://github.com/ryanoasis/nerd-fonts/releases/download/v3.3.0/FiraCode.zip && unzip FiraCode.zip *.ttf -d ~/.local/share/fonts/
|
||||
printf "You'll need to relog to have your default shell changed\n"
|
||||
|
||||
# Install background and hyprland stuff
|
||||
ensure_installed hyprland hyprpaper hypridle hyprlock hyprsunset
|
||||
mkdir -p ~/.local/share/backgrounds/
|
||||
curl -o ~/.local/share/backgrounds/eKxlw8.jpg -fsSL "https://live.staticflickr.com/5077/5914101671_d80c6591e8_k.jpg"
|
||||
# desktop elements that just work
|
||||
ensure_installed swaync
|
||||
ensure_installed waybar fontawesome4-fonts
|
||||
|
||||
# Install sddm
|
||||
ensure_installed sddm qt6-qtsvg qt5-qtquickcontrols2
|
||||
sudo cp ~/.config/sddm/sddm.conf /etc/sddm.conf
|
||||
sudo cp -r ~/.config/sddm/themes/catpuccin-macchiatto /usr/share/sddm/themes/
|
||||
|
||||
# Install grub
|
||||
ensure_installed grub2-common
|
||||
replace_config_line "/etc/default/grub" "GRUB_THEME" "/boot/themes/catppuccin-macchiato-grub-theme/theme.txt"
|
||||
sudo cp -r ~/.config/grub/themes/ /boot/themes
|
||||
sudo grub2-mkconfig -o /boot/grub2/grub.cfg
|
||||
|
||||
# Install plymouth
|
||||
ensure_installed plymouth plymouth-plugin-two-step
|
||||
sudo cp -r ~/.config/plymouth/themes/fedora-mac-style /usr/share/plymouth/themes/
|
||||
sudo plymouth-set-default-theme -R fedora-mac-style && sudo dracut --regenerate-all -f
|
||||
|
||||
# install gnome's stuff
|
||||
ensure_installed gnome-keying nautilus dconf gedit
|
||||
dconf load /org/gtk/gtk4 < ~/.config/dconf-export/gtk4.dconf
|
||||
dconf load /org/gnome/desktop < ~/.config/dconf-export/gnome-desktop.dconf
|
||||
dconf load /org/gnome/nautilus < ~/.config/dconf-export/nautilus.dconf
|
||||
dconf load /org/gnome/gedit < ~/.config/dconf-export/gedit.dconf
|
||||
|
||||
# rofi & rofi-calc (compilation, because why not)
|
||||
sudo dnf install --allowerasing --assumeyes https://kojipkgs.fedoraproject.org//packages/rofi-wayland/1.7.5+wayland2/3.fc40/$(uname -m)/rofi-wayland-1.7.5+wayland2-3.fc40.$(uname -m).rpm
|
||||
ensure_installed rofi-devel qalculate automake libtool
|
||||
git clone https://github.com/svenstaro/rofi-calc && cd rofi-calc && mkdir m4 && autoreconf -i && mkdir build && cd build && ../configure && make && sudo make install && cd ../.. && rm -rf rofi-calc
|
||||
|
||||
# kdeconnect
|
||||
ensure_installed kdeconnectd
|
||||
sudo firewall-cmd --permanent --add-service=kdeconnect
|
||||
printf "You'll need to relog for kdeconnect to work\n"
|
||||
|
||||
# flatpaks
|
||||
flatpak remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo
|
||||
flatpak install flatseal librewolf
|
||||
|
||||
# set up neovim
|
||||
ensure_installed neovim clang unzip npm ripgrep go
|
||||
nvim
|
||||
|
||||
# to finalize it all
|
||||
printf 'Press enter to reboot, ctrl+c to exit'
|
||||
read -r response && sudo reboot now
|
||||
@@ -1,9 +0,0 @@
|
||||
GRUB_TIMEOUT=3
|
||||
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
|
||||
GRUB_DEFAULT=saved
|
||||
GRUB_DISABLE_SUBMENU=true
|
||||
# GRUB_TERMINAL_OUTPUT="console"
|
||||
GRUB_CMDLINE_LINUX="rd.luks.uuid=luks-5e345064-0ca5-4162-a7ef-624907ae9adf rhgb quiet"
|
||||
GRUB_DISABLE_RECOVERY="true"
|
||||
GRUB_ENABLE_BLSCFG=true
|
||||
GRUB_THEME="/boot/themes/catppuccin-macchiato-grub-theme/theme.txt"
|
||||
Reference in New Issue
Block a user