|
@@ -48,10 +48,6 @@ rm -rf /etc/pacman.d/gnupg
|
|
|
pacman-key --init
|
|
pacman-key --init
|
|
|
pacman-key --populate archlinux
|
|
pacman-key --populate archlinux
|
|
|
|
|
|
|
|
-# add sublime text source
|
|
|
|
|
-curl -O https://download.sublimetext.com/sublimehq-pub.gpg && pacman-key --add sublimehq-pub.gpg && pacman-key --lsign-key 8A8F901A && rm sublimehq-pub.gpg
|
|
|
|
|
-[ $(grep -c "sublime-text" /etc/pacman.conf) -eq 0 ] && echo -e "\n[sublime-text]\nServer = https://download.sublimetext.com/arch/stable/x86_64" | tee -a /etc/pacman.conf
|
|
|
|
|
-
|
|
|
|
|
# Core tools
|
|
# Core tools
|
|
|
export PACKAGES="linux linux-headers linux-firmware base-devel mkinitcpio sudo bash-completion man-db tmux gvim dkms dmidecode at bc cronie lm_sensors lshw stress"
|
|
export PACKAGES="linux linux-headers linux-firmware base-devel mkinitcpio sudo bash-completion man-db tmux gvim dkms dmidecode at bc cronie lm_sensors lshw stress"
|
|
|
|
|
|
|
@@ -81,7 +77,7 @@ PACKAGES="${PACKAGES} pkgfile pkgconf bison gcc gcc-libs cmake ccache ncurses li
|
|
|
PACKAGES="${PACKAGES} mesa lib32-mesa dbus polkit giflib lib32-giflib mpg123 lib32-mpg123 v4l-utils lib32-v4l-utils lame libwebp libid3tag libvorbis vorbis-tools faac x264 x265 libldap lib32-libldap libpng lib32-libpng libpng12 lib32-libpng12 libjpeg-turbo lib32-libjpeg-turbo pipewire lib32-pipewire pipewire-jack lib32-pipewire-jack pipewire-alsa pipewire-pulse pipewire-zeroconf wireplumber openal lib32-openal alsa-plugins lib32-alsa-plugins alsa-lib lib32-alsa-lib opencl-icd-loader lib32-opencl-icd-loader libva lib32-libva libva-utils gst-plugins-base-libs lib32-gst-plugins-base-libs graphicsmagick imagemagick joyutils evtest libexif ffmpeg lxsession-gtk3 yt-dlp wine-staging winetricks fcitx5 fcitx5-mozc fcitx5-configtool fcitx5-gtk fcitx5-qt"
|
|
PACKAGES="${PACKAGES} mesa lib32-mesa dbus polkit giflib lib32-giflib mpg123 lib32-mpg123 v4l-utils lib32-v4l-utils lame libwebp libid3tag libvorbis vorbis-tools faac x264 x265 libldap lib32-libldap libpng lib32-libpng libpng12 lib32-libpng12 libjpeg-turbo lib32-libjpeg-turbo pipewire lib32-pipewire pipewire-jack lib32-pipewire-jack pipewire-alsa pipewire-pulse pipewire-zeroconf wireplumber openal lib32-openal alsa-plugins lib32-alsa-plugins alsa-lib lib32-alsa-lib opencl-icd-loader lib32-opencl-icd-loader libva lib32-libva libva-utils gst-plugins-base-libs lib32-gst-plugins-base-libs graphicsmagick imagemagick joyutils evtest libexif ffmpeg lxsession-gtk3 yt-dlp wine-staging winetricks fcitx5 fcitx5-mozc fcitx5-configtool fcitx5-gtk fcitx5-qt"
|
|
|
|
|
|
|
|
# GUI theme
|
|
# GUI theme
|
|
|
-PACKAGES="${PACKAGES} gnome-themes-extra hicolor-icon-theme arc-gtk-theme gtk-engines gtk-engine-murrine"
|
|
|
|
|
|
|
+PACKAGES="${PACKAGES} gnome-themes-extra hicolor-icon-theme"
|
|
|
|
|
|
|
|
# GUI dependencies
|
|
# GUI dependencies
|
|
|
PACKAGES="${PACKAGES} gtk3 lib32-gtk3 pavucontrol pcmanfm-gtk3 ffmpegthumbnailer tumbler xdg-utils xdg-user-dirs libxcomposite lib32-libxcomposite libxinerama lib32-libxinerama libxslt lib32-libxslt"
|
|
PACKAGES="${PACKAGES} gtk3 lib32-gtk3 pavucontrol pcmanfm-gtk3 ffmpegthumbnailer tumbler xdg-utils xdg-user-dirs libxcomposite lib32-libxcomposite libxinerama lib32-libxinerama libxslt lib32-libxslt"
|
|
@@ -93,24 +89,29 @@ PACKAGES="${PACKAGES} libva-mesa-driver lib32-libva-mesa-driver lib32-mesa-vdpau
|
|
|
PACKAGES="${PACKAGES} sway swaybg alacritty wofi waybar xorg-xwayland xorg-xlsclients wev qt5-wayland glfw-x11 grim slurp xdg-desktop-portal-wlr libpipewire lib32-libpipewire wl-clipboard brightnessctl playerctl mako libappindicator-gtk3 lib32-libappindicator-gtk3"
|
|
PACKAGES="${PACKAGES} sway swaybg alacritty wofi waybar xorg-xwayland xorg-xlsclients wev qt5-wayland glfw-x11 grim slurp xdg-desktop-portal-wlr libpipewire lib32-libpipewire wl-clipboard brightnessctl playerctl mako libappindicator-gtk3 lib32-libappindicator-gtk3"
|
|
|
|
|
|
|
|
# fonts
|
|
# fonts
|
|
|
-PACKAGES="${PACKAGES} fontconfig ttf-bitstream-vera ttf-droid ttf-dejavu ttf-liberation ttf-hanazono ttf-font-awesome"
|
|
|
|
|
|
|
+PACKAGES="${PACKAGES} fontconfig ttf-bitstream-vera ttf-droid ttf-dejavu ttf-liberation ttf-hanazono ttf-jigmo ttf-roboto ttf-sazanami ttf-vlgothic ttf-font-awesome otf-font-awesome"
|
|
|
|
|
|
|
|
# GUI software
|
|
# GUI software
|
|
|
-PACKAGES="${PACKAGES} xarchiver gparted psensor steam steam-native-runtime gamemode gamescope mangohud lib32-mangohud lib32-gamemode discord mpv mpv-mpris openshot gimp krita firefox obs-studio mednafen mame ppsspp lutris sublime-text evince viewnior virt-manager virtualbox virtualbox-host-modules-arch corectrl"
|
|
|
|
|
|
|
+PACKAGES="${PACKAGES} xarchiver gparted psensor steam steam-native-runtime gamemode gamescope mangohud lib32-mangohud lib32-gamemode discord mpv mpv-mpris openshot gimp krita obs-studio mednafen mame ppsspp lutris neovim evince virt-manager virtualbox virtualbox-host-modules-arch"
|
|
|
|
|
|
|
|
-# conditional GPU packages
|
|
|
|
|
|
|
+# conditional AMD GPU packages
|
|
|
if [ $(lspci | grep -i "vga" | grep -ci "amd") -gt 0 ]; then
|
|
if [ $(lspci | grep -i "vga" | grep -ci "amd") -gt 0 ]; then
|
|
|
PACKAGES="${PACKAGES} xf86-video-amdgpu vulkan-radeon lib32-vulkan-radeon mesa-vdpau"
|
|
PACKAGES="${PACKAGES} xf86-video-amdgpu vulkan-radeon lib32-vulkan-radeon mesa-vdpau"
|
|
|
|
|
|
|
|
# update modules to load
|
|
# update modules to load
|
|
|
[ $(grep -c "amd" /etc/mkinitcpio.conf) -eq 0 ] && sed -i 's/MODULES=(\(.*\))/MODULES=(\1 amdgpu radeon)/' /etc/mkinitcpio.conf
|
|
[ $(grep -c "amd" /etc/mkinitcpio.conf) -eq 0 ] && sed -i 's/MODULES=(\(.*\))/MODULES=(\1 amdgpu radeon)/' /etc/mkinitcpio.conf
|
|
|
fi
|
|
fi
|
|
|
|
|
+
|
|
|
|
|
+# conditional Intel GPU packages
|
|
|
if [ $(lspci | grep -i "vga" | grep -ci "intel") -gt 0 ]; then
|
|
if [ $(lspci | grep -i "vga" | grep -ci "intel") -gt 0 ]; then
|
|
|
PACKAGES="${PACKAGES} xf86-video-intel vulkan-intel lib32-vulkan-intel mesa-vdpau"
|
|
PACKAGES="${PACKAGES} xf86-video-intel vulkan-intel lib32-vulkan-intel mesa-vdpau"
|
|
|
|
|
|
|
|
# update modules to load
|
|
# update modules to load
|
|
|
[ $(grep -c "amd" /etc/mkinitcpio.conf) -eq 0 ] && sed -i 's/MODULES=(\(.*\))/MODULES=(\1 i915)/' /etc/mkinitcpio.conf
|
|
[ $(grep -c "amd" /etc/mkinitcpio.conf) -eq 0 ] && sed -i 's/MODULES=(\(.*\))/MODULES=(\1 i915)/' /etc/mkinitcpio.conf
|
|
|
fi
|
|
fi
|
|
|
|
|
+
|
|
|
|
|
+# conditional nVidia GPU packages
|
|
|
|
|
+# @note: untested since 2019; I stopped using nvidia
|
|
|
if [ $(lspci | grep -i "vga" | grep -ci "nvidia") -gt 0 ]; then
|
|
if [ $(lspci | grep -i "vga" | grep -ci "nvidia") -gt 0 ]; then
|
|
|
PACKAGES="${PACKAGES} nvidia-dkms libglvnd lib32-libglvnd opencl-nvidia lib32-opencl-nvidia xf86-video-nouveau nvidia-utils lib32-nvidia-utils mesa-vdpau nvidia-settings"
|
|
PACKAGES="${PACKAGES} nvidia-dkms libglvnd lib32-libglvnd opencl-nvidia lib32-opencl-nvidia xf86-video-nouveau nvidia-utils lib32-nvidia-utils mesa-vdpau nvidia-settings"
|
|
|
|
|
|
|
@@ -129,54 +130,13 @@ pacman -Syu --noconfirm $PACKAGES
|
|
|
[ -d /srv/arch-desktop/install ] || git clone https://git.caseydelorme.com/cdelorme/arch-desktop /srv/arch-desktop
|
|
[ -d /srv/arch-desktop/install ] || git clone https://git.caseydelorme.com/cdelorme/arch-desktop /srv/arch-desktop
|
|
|
rsync -Pav /srv/arch-desktop/install/ /
|
|
rsync -Pav /srv/arch-desktop/install/ /
|
|
|
mkdir -p /etc/skel/{desktop,downloads,public,public/templates,documents,music,pictures,videos,code}
|
|
mkdir -p /etc/skel/{desktop,downloads,public,public/templates,documents,music,pictures,videos,code}
|
|
|
-# @todo: verify if these is necessary /w pipewire-pulse
|
|
|
|
|
-#mkdir -p /etc/skel/.config/pulse
|
|
|
|
|
-# sed "/module-suspend-on-idle/d" /etc/pulse/default.pa > /etc/skel/.config/pulse/default.pa
|
|
|
|
|
-# sed -i "/module-switch-on-port-available/d" /etc/skel/.config/pulse/default.pa
|
|
|
|
|
rsync -Pav /etc/skel/ "$(getent passwd root | cut -d: -f6)/"
|
|
rsync -Pav /etc/skel/ "$(getent passwd root | cut -d: -f6)/"
|
|
|
sed -i "/ssh-add/d" "$(getent passwd root | cut -d: -f6)/.bashrc"
|
|
sed -i "/ssh-add/d" "$(getent passwd root | cut -d: -f6)/.bashrc"
|
|
|
|
|
|
|
|
-# install protontricks
|
|
|
|
|
-# python3 -m pip install protontricks
|
|
|
|
|
-
|
|
|
|
|
# enable ccache and optimize cores for AUR
|
|
# enable ccache and optimize cores for AUR
|
|
|
sed -i 's/!ccache/ccache/' /etc/makepkg.conf
|
|
sed -i 's/!ccache/ccache/' /etc/makepkg.conf
|
|
|
sed -i 's/^#MAKEFLAGS.*/MAKEFLAGS="-j$(($(nproc) + 1)) -l$(nproc)"/' /etc/makepkg.conf
|
|
sed -i 's/^#MAKEFLAGS.*/MAKEFLAGS="-j$(($(nproc) + 1)) -l$(nproc)"/' /etc/makepkg.conf
|
|
|
|
|
|
|
|
-# create a user to install aur packages
|
|
|
|
|
-export aur_username=$(head /dev/urandom | tr -dc a-z | head -c 13 ; echo '')
|
|
|
|
|
-useradd -r -m -s /bin/bash $aur_username
|
|
|
|
|
-echo "${aur_username} ALL= NOPASSWD: /usr/bin/pacman" > /etc/sudoers.d/${aur_username}
|
|
|
|
|
-
|
|
|
|
|
-# install vimix-cursors
|
|
|
|
|
-sudo -u $aur_username git clone https://aur.archlinux.org/vimix-cursors.git /home/${aur_username}/vimix-cursors
|
|
|
|
|
-(cd /home/${aur_username}/vimix-cursors && sudo -u ${aur_username} makepkg -rcsi --noconfirm)
|
|
|
|
|
-
|
|
|
|
|
-# install numix-icon-theme
|
|
|
|
|
-sudo -u $aur_username git clone https://aur.archlinux.org/numix-icon-theme-git.git /home/${aur_username}/numix-icon-theme-git
|
|
|
|
|
-(cd /home/${aur_username}/numix-icon-theme-git && sudo -u ${aur_username} makepkg -rcsi --noconfirm)
|
|
|
|
|
-
|
|
|
|
|
-# cmst (for connman UI)
|
|
|
|
|
-sudo -u $aur_username git clone https://aur.archlinux.org/cmst.git /home/${aur_username}/cmst
|
|
|
|
|
-(cd /home/${aur_username}/cmst && sudo -u ${aur_username} makepkg -rcsi --noconfirm)
|
|
|
|
|
-
|
|
|
|
|
-# cleanup aur user
|
|
|
|
|
-rm -rf /etc/sudoers.d/${aur_username}
|
|
|
|
|
-userdel -fr $aur_username
|
|
|
|
|
-unset $aur_username
|
|
|
|
|
-
|
|
|
|
|
-# install gifduration
|
|
|
|
|
-if ! which gifduration &> /dev/null; then
|
|
|
|
|
- curl -Lfs https://raw.githubusercontent.com/alimony/gifduration-script/master/gifduration.py > /usr/local/bin/gifduration
|
|
|
|
|
- chmod a+rx /usr/local/bin/gifduration
|
|
|
|
|
-fi
|
|
|
|
|
-
|
|
|
|
|
-# install 64bit flash projector
|
|
|
|
|
-if ! which flashplayer &> /dev/null; then
|
|
|
|
|
- curl -Lfs "https://fpdownload.macromedia.com/pub/flashplayer/updaters/32/flash_player_sa_linux.x86_64.tar.gz" > /tmp/flash.tar.gz
|
|
|
|
|
- tar -xf /tmp/flash.tar.gz -C /usr/local/bin flashplayer
|
|
|
|
|
-fi
|
|
|
|
|
-
|
|
|
|
|
# create sudo group and add to sudoers
|
|
# create sudo group and add to sudoers
|
|
|
groupadd -fr sudo
|
|
groupadd -fr sudo
|
|
|
[ ! -f /etc/sudoers.d/sudo ] && echo '%sudo ALL=(ALL) ALL' > /etc/sudoers.d/sudo
|
|
[ ! -f /etc/sudoers.d/sudo ] && echo '%sudo ALL=(ALL) ALL' > /etc/sudoers.d/sudo
|
|
@@ -231,7 +191,9 @@ su $username -c "cd; if [ ! -f ~/.ssh/id_ed25519 ]; then ssh-keygen -q -t ed2551
|
|
|
# install gvm loading from ~/.bashrc & ~/.bash_profile, and the latest go version
|
|
# install gvm loading from ~/.bashrc & ~/.bash_profile, and the latest go version
|
|
|
su $username -c "if [ ! -d ~/.gvm ]; then GVM_NO_UPDATE_PROFILE=1 bash < <(curl -Ls https://raw.githubusercontent.com/moovweb/gvm/master/binscripts/gvm-installer 2> /dev/null); fi"
|
|
su $username -c "if [ ! -d ~/.gvm ]; then GVM_NO_UPDATE_PROFILE=1 bash < <(curl -Ls https://raw.githubusercontent.com/moovweb/gvm/master/binscripts/gvm-installer 2> /dev/null); fi"
|
|
|
su $username -c 'grep "gvm" ~/.bash_profile &> /dev/null || echo -e "\n# load gvm\n[ -s $HOME/.gvm/scripts/gvm ] && . $HOME/.gvm/scripts/gvm" >> ~/.bash_profile'
|
|
su $username -c 'grep "gvm" ~/.bash_profile &> /dev/null || echo -e "\n# load gvm\n[ -s $HOME/.gvm/scripts/gvm ] && . $HOME/.gvm/scripts/gvm" >> ~/.bash_profile'
|
|
|
-su $username -c ". ~/.gvm/scripts/gvm && gvm install go1.21.3 -B && gvm use go1.21.3 --default"
|
|
|
|
|
|
|
+su $username -c ". ~/.gvm/scripts/gvm && gvm install go1.26.1 -B && gvm use go1.26.1 --default"
|
|
|
|
|
+# @note: fix stupid fucking cd override in gvm scripts
|
|
|
|
|
+su $username -c "[ -f ~/.gvm/scripts/env/cd ] && mv ~/.gvm/scripts/env/cd ~/.gvm/scripts/env/cd.bak && touch ~/.gvm/scripts/env/cd"
|
|
|
|
|
|
|
|
# configure user-space transmission
|
|
# configure user-space transmission
|
|
|
if [ ! -f "/etc/systemd/system/transmission.service.d/local.conf" ]; then
|
|
if [ ! -f "/etc/systemd/system/transmission.service.d/local.conf" ]; then
|
|
@@ -239,6 +201,30 @@ if [ ! -f "/etc/systemd/system/transmission.service.d/local.conf" ]; then
|
|
|
su $username -c 'cd && tmp=$(mktemp) && jq ".[\"download-dir\"] = \"${HOME}/transmission/done\"" $HOME/.config/transmission-daemon/settings.json | jq ".[\"incomplete-dir\"] = \"${HOME}/transmission/incomplete\"" | jq ".[\"watch-dir\"] = \"$(xdg-user-dir DOWNLOAD)\"" > $tmp && mv $tmp $HOME/.config/transmission-daemon/settings.json'
|
|
su $username -c 'cd && tmp=$(mktemp) && jq ".[\"download-dir\"] = \"${HOME}/transmission/done\"" $HOME/.config/transmission-daemon/settings.json | jq ".[\"incomplete-dir\"] = \"${HOME}/transmission/incomplete\"" | jq ".[\"watch-dir\"] = \"$(xdg-user-dir DOWNLOAD)\"" > $tmp && mv $tmp $HOME/.config/transmission-daemon/settings.json'
|
|
|
fi
|
|
fi
|
|
|
|
|
|
|
|
|
|
+su -u $username -c "mkdir -p ~/code/aur.archlinux.org"
|
|
|
|
|
+export user_home="$(getent passwd $username | cut -d: -f6)/"
|
|
|
|
|
+
|
|
|
|
|
+# install qview
|
|
|
|
|
+sudo -u $username git clone https://aur.archlinux.org/qview.git ${user_home}/aur.archlinux.org/qview
|
|
|
|
|
+(cd ${user_home}/aur.archlinux.org/qview && sudo -u ${username} makepkg -rcsi --noconfirm)
|
|
|
|
|
+
|
|
|
|
|
+# cmst (for connman UI)
|
|
|
|
|
+sudo -u $username git clone https://aur.archlinux.org/cmst.git ${user_home}/aur.archlinux.org/cmst
|
|
|
|
|
+(cd ${user_home}/aur.archlinux.org/cmst && sudo -u ${username} makepkg -rcsi --noconfirm)
|
|
|
|
|
+
|
|
|
|
|
+# brave browser (plus override to bypass keyring)
|
|
|
|
|
+sudo -u $username git clone https://aur.archlinux.org/brave-bin.git ${user_home}/aur.archlinux.org/brave-bin
|
|
|
|
|
+(cd ${user_home}/aur.archlinux.org/brave-bin && sudo -u ${username} makepkg -rcsi --noconfirm)
|
|
|
|
|
+[ -f /usr/share/applications/brave-browser.desktop ] && sed -i 's|Exec=brave|Exec=brave --password-store=basic|g' /usr/share/applications/brave-browser.desktop
|
|
|
|
|
+
|
|
|
|
|
+# install vimix-cursors
|
|
|
|
|
+sudo -u $username git clone https://aur.archlinux.org/vimix-cursors.git ${user_home}/aur.archlinux.org/vimix-cursors
|
|
|
|
|
+(cd ${user_home}/aur.archlinux.org/vimix-cursors && sudo -u ${username} makepkg -rcsi --noconfirm)
|
|
|
|
|
+
|
|
|
|
|
+# install numix-icon-theme
|
|
|
|
|
+sudo -u $username git clone https://aur.archlinux.org/numix-icon-theme-git.git ${user_home}/aur.archlinux.org/numix-icon-theme-git
|
|
|
|
|
+(cd ${user_home}/aur.archlinux.org/numix-icon-theme-git && sudo -u ${username} makepkg -rcsi --noconfirm)
|
|
|
|
|
+
|
|
|
# symlink shceduled maintenance tasks
|
|
# symlink shceduled maintenance tasks
|
|
|
#ln -sf /usr/local/bin/system-updates /etc/cron.daily/system-updates
|
|
#ln -sf /usr/local/bin/system-updates /etc/cron.daily/system-updates
|
|
|
ln -sf /usr/local/bin/disk-maintenance /etc/cron.weekly/disk-maintenance
|
|
ln -sf /usr/local/bin/disk-maintenance /etc/cron.weekly/disk-maintenance
|