From 378cab2ec31574daae3f8332cf30924214b58c8f Mon Sep 17 00:00:00 2001 From: Yaroslav Date: Mon, 29 Jun 2020 05:46:13 +0300 Subject: artix-specific stuff; use pacmixer instead of ncpamixer --- README.md | 2 +- artix.sh | 29 +++++++++++++++++++++++++++++ dotfiles/.config/sway/config | 3 ++- dotfiles/.local/bin/menublk | 2 +- dotfiles/.profile | 7 +++++-- install.sh | 4 ++-- system/mkinitcpio.conf | 2 +- 7 files changed, 41 insertions(+), 8 deletions(-) create mode 100755 artix.sh diff --git a/README.md b/README.md index 494ed59..bfb910d 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ # Yaroslav's sway rice -My own config files for my setup of sway. Should work on any distro, however it is optimized for Arch Linux. +My own config files for my setup of sway. Should work on any distro, however it is optimized for Artix/Arch Linux. diff --git a/artix.sh b/artix.sh new file mode 100755 index 0000000..b0a699d --- /dev/null +++ b/artix.sh @@ -0,0 +1,29 @@ +#!/bin/sh + +# Very basic helper script to install some programs and configs for an +# Artix+runit+Sway system + +pacman -Sy --noconfirm zsh zsh-syntax-highlighting openresolv wireguard-tools bind-tools sway swaylock swayidle waybar egl-wayland imv swaybg xorg-server-xwayland termite kitty qt5-wayland wl-clipboard dbus tmux htop bemenu bemenu-wlroots mupdf mpd ncmpcpp mpc mpv libnotify mako cronie cronie-runit metalog metalog-runit dnsmasq dnsmasq-runit networkmanager networkmanager-runit rsync grim slurp ffmpeg w3m youtube-dl youtube-viewer newsboat wget curl inkscape gimp darktable gcc make fontconfig pkg-config fakeroot papirus-icon-theme alsa-utils pulseaudio pamixer pulseaudio-bluetooth imagemagick ntfs-3g unzip unrar gnome-themes-standard telegram-desktop qt5ct r bc udisks2 perl-term-readline-gnu transmission-cli transmission-remote-gtk python-pynvim python-pip python-pillow calcurse acpi acpid gnupg noto-fonts-cjk noto-fonts-emoji ttf-joypixels otf-latin-modern otf-latinmodern-math powerline-fonts python-pygit2 polkit polkit-gnome zathura zathura-pdf-mupdf zathura-djvu gst-libav vifm blueman bluez bluez-runit acpilight accountsservice lightdm xdg-user-dirs abook ranger terminus-font qutebrowser jq stow wdiff texlive-most units isync notmuch pass translate-shell gnome-keyring pacman-contrib + +# Copy system config files +cp system/sudoers /etc/ +cp system/resolvconf.conf /etc/ +cp system/NetworkManager/NetworkManager.conf /etc/NetworkManager/NetworkManager.conf +cp system/mkinitcpio.conf /etc/ +cp system/pam.d/* /etc/pam.d/ + +resolvconf -u + +# Install AUR helper +cd /tmp +mkdir build +chown -R "$1:$1" build +cd build +sudo -u "$1" "git clone https://aur.archlinux.org/yay.git && cd yay && makepkg -si" + +yay -S --noconfirm aerc-git ttf-symbola pam-gnupg pacmixer mimeo xdg-utils-mimeo cli-visualizer + +# Copy some fonts to make them available system-wide +mkdir -p /usr/share/fonts/rice +cp system/fonts/* /usr/share/fonts/rice/ + diff --git a/dotfiles/.config/sway/config b/dotfiles/.config/sway/config index 5504b6e..b80bf3f 100644 --- a/dotfiles/.config/sway/config +++ b/dotfiles/.config/sway/config @@ -67,6 +67,7 @@ set $ws10 10 # Open specific applications in specific modes for_window [title="alsamixer"] floating enable for_window [title="ncpamixer"] floating enable +for_window [title="pacmixer"] floating enable for_window [title="nmtui"] floating enable for_window [title="i3_help"] floating enable, sticky enable for_window [class="Lightdm-settings"] floating enable @@ -210,7 +211,7 @@ bindsym --to-code { Ctrl+Print exec --no-startup-id swayrecord # Sound - $mod+Shift+m exec $term -e 'ncpamixer' + $mod+Shift+m exec $term -e 'pacmixer' $mod+Ctrl+m exec --no-startup-id menuoutput # Applications that start with no gaps diff --git a/dotfiles/.local/bin/menublk b/dotfiles/.local/bin/menublk index 3c507ac..cfc1a7b 100755 --- a/dotfiles/.local/bin/menublk +++ b/dotfiles/.local/bin/menublk @@ -42,7 +42,7 @@ get_unmountable() { if [ -z "$mountpoint" ] && [ "$fstype" = "crypto_LUKS" ]; then mountpoint="$(lsblk -r -o MOUNTPOINT "/dev/$name" | tail -n 1)" fi - if [ -n "$mountpoint" ] && [ "$mountpoint" != "/" ] && [ "$mountpoint" != "/boot" ] + if [ -n "$mountpoint" ] && [ "$mountpoint" != "/" ] && [ "$mountpoint" != "/boot" ] && [ "$mountpoint" != "[SWAP]" ] then echo "$name" fi diff --git a/dotfiles/.profile b/dotfiles/.profile index d849ada..76288ac 100644 --- a/dotfiles/.profile +++ b/dotfiles/.profile @@ -25,14 +25,17 @@ eval "$(sed 's/^[^#].*/export &/g;t;d' ~/.config/user-dirs.dirs)" export LESSHISTFILE="-" export ZDOTDIR="$XDG_CONFIG_HOME/zsh" export INPUTRC="$XDG_CONFIG_HOME/zsh/inputrc" +export WEECHAT_HOME="$XDG_CONFIG_HOME/weechat" export CARGO_HOME="$XDG_DATA_HOME/cargo" export RUSTUP_HOME="$XDG_DATA_HOME/rustup" export PASSWORD_STORE_DIR="$XDG_DATA_HOME/password-store" export GTK2_RC_FILES="$XDG_CONFIG_HOME/gtk-2.0/gtkrc-2.0" eval "$(dircolors "$HOME/.config/dir_colors")" -# Start sway automatically upon login on tty1 -if [[ -z $DISPLAY ]] && [[ $(tty) = /dev/tty1 ]]; then +# Start sway automatically upon login on tty1 or tty2 +if [ -z $DISPLAY ] && [ $(tty) = /dev/tty1 ] || [ $(tty) = /dev/tty2 ]; then + # DBUS variables (for Artix) + export $(dbus-launch) sway > ~/.cache/sway.log 2>&1 && clear && exit fi diff --git a/install.sh b/install.sh index d7740d4..b792183 100755 --- a/install.sh +++ b/install.sh @@ -11,7 +11,7 @@ fi CLONEDIR=$PWD # Install some basic programs -pacman -Sy --noconfirm base-devel zsh man networkmanager openresolv wireguard-tools bind-tools neovim sway swaylock swayidle waybar egl-wayland imv swaybg xorg-server-xwayland termite kitty qt5-wayland wl-clipboard dbus tmux htop bemenu mupdf mpd ncmpcpp mpc mpv mplayer libnotify mako cronie rsync grim slop ffmpeg w3m youtube-dl youtube-viewer newsboat wget curl krita inkscape darktable gcc make fontconfig pkg-config fakeroot papirus-icon-theme alsa-utils pulseaudio pulseaudio-bluetooth imagemagick ntfs-3g unzip unrar gnome-themes-standard gtk-engine-murrine telegram-desktop qt5ct r bc udisks2 perl-term-readline-gnu transmission-cli transmission-remote-gtk python-pynvim python-pip python-pillow calcurse acpi acpid gnupg noto-fonts-cjk noto-fonts-emoji ttf-joypixels otf-latin-modern otf-latinmodern-math powerline-fonts python-pygit2 polkit polkit-gnome zathura zathura-pdf-mupdf zathura-djvu gst-libav vifm blueman bluez acpilight powertop accountsservice lightdm xdg-user-dirs abook ranger terminus-font qutebrowser jq stow wdiff texlive-most pandoc units isync notmuch +pacman -Sy --noconfirm base-devel zsh zsh-syntax-highlighting man networkmanager openresolv wireguard-tools bind-tools neovim sway swaylock swayidle waybar egl-wayland imv swaybg xorg-server-xwayland termite kitty qt5-wayland wl-clipboard dbus tmux htop bemenu mupdf mpd ncmpcpp mpc mpv libnotify mako cronie rsync grim slop ffmpeg w3m youtube-dl youtube-viewer newsboat wget curl krita inkscape darktable gcc make fontconfig pkg-config fakeroot papirus-icon-theme alsa-utils pulseaudio pamixer pulseaudio-bluetooth imagemagick ntfs-3g unzip unrar gnome-themes-standard gtk-engine-murrine telegram-desktop qt5ct r bc udisks2 perl-term-readline-gnu transmission-cli transmission-remote-gtk python-pynvim python-pip python-pillow calcurse acpi acpid gnupg noto-fonts-cjk noto-fonts-emoji ttf-joypixels otf-latin-modern otf-latinmodern-math powerline-fonts python-pygit2 polkit polkit-gnome zathura zathura-pdf-mupdf zathura-djvu gst-libav vifm blueman bluez acpilight powertop accountsservice lightdm xdg-user-dirs abook ranger terminus-font qutebrowser jq stow wdiff texlive-most pandoc units isync notmuch gnome-keyring pacman-contrib # Copy system config files cp system/sudoers /etc/ @@ -38,7 +38,7 @@ chown -R "$1:$1" build cd build sudo -u "$1" "git clone https://aur.archlinux.org/yay.git && cd yay && makepkg -si" -yay -S --noconfirm aerc-git ttf-symbola stig pam-gnupg ncpamixer lightdm-mini-greeter plymouth-git mimeo xdg-utils-mimeo cli-visualizer +yay -S --noconfirm aerc-git ttf-symbola pam-gnupg pacmixer mimeo xdg-utils-mimeo cli-visualizer cd "$CLONEDIR" diff --git a/system/mkinitcpio.conf b/system/mkinitcpio.conf index 02dfa15..33a5ac2 100644 --- a/system/mkinitcpio.conf +++ b/system/mkinitcpio.conf @@ -49,7 +49,7 @@ FILES=() # ## NOTE: If you have /usr on a separate partition, you MUST include the # usr, fsck and shutdown hooks. -HOOKS=(base udev plymouth autodetect keyboard keymap modconf block plymouth-encrypt lvm2 filesystems fsck) +HOOKS=(base udev autodetect modconf block consolefont filesystems keyboard fsck) # COMPRESSION # Use this to compress the initramfs image. By default, gzip compression -- cgit v1.2.3