Compare commits

..

17 Commits

13 changed files with 115 additions and 39 deletions

View File

@ -35,35 +35,27 @@ help () {
[ "$( wc -l "$FILE" | cut -d ' ' -f 1 )" != "16" ] && help && exit [ "$( wc -l "$FILE" | cut -d ' ' -f 1 )" != "16" ] && help && exit
NB="" COLOR00="$(sed '1!d' "$FILE")"
NF="" COLOR01="$(sed '2!d' "$FILE")"
HB="" COLOR02="$(sed '3!d' "$FILE")"
HF="" COLOR03="$(sed '4!d' "$FILE")"
SB="" COLOR04="$(sed '5!d' "$FILE")"
SF="" COLOR05="$(sed '6!d' "$FILE")"
TB="" COLOR06="$(sed '7!d' "$FILE")"
TF="" COLOR07="$(sed '8!d' "$FILE")"
FB="" COLOR08="$(sed '9!d' "$FILE")"
FF="#ffffff" COLOR09="$(sed '10!d' "$FILE")"
COLOR0A="$(sed '11!d' "$FILE")"
COLOR0B="$(sed '12!d' "$FILE")"
COLOR0C="$(sed '13!d' "$FILE")"
COLOR0D="$(sed '14!d' "$FILE")"
COLOR0E="$(sed '15!d' "$FILE")"
COLOR0F="$(sed '16!d' "$FILE")"
IFS='
'
COUNT=0
for LINE in $(cat "$FILE")
do
case $COUNT in
0) NB="$LINE" && HB="$LINE" && TB="$LINE" && FB="$LINE";;
1) SB="$LINE";;
6) HF="$LINE" && SF="$LINE";;
10) NF="$LINE" && TF="$LINE";;
esac
COUNT=$((COUNT + 1))
done
echo "bemenu colors updated." echo "bemenu colors updated."
echo "#!/bin/sh" > "$BEMENUOPTS_FILE" echo "#!/bin/sh" > "$BEMENUOPTS_FILE"
echo "#generated from: $1" >> "$BEMENUOPTS_FILE" echo "#generated from: $1" >> "$BEMENUOPTS_FILE"
echo "export BEMENU_OPTS=\"-H $HEIGHT --nb $NB --nf $NF --hb $HB --hf $HF --sb $SB --sf $SF --tb $TB --tf $TF --fb $FB --ff $FF\"" >> "$BEMENUOPTS_FILE" #echo "export BEMENU_OPTS=\"-H $HEIGHT --tb $COLOR03 --tf $COLOR06 --fb $COLOR00 --ff $COLOR06 --nb $COLOR00 --nf $COLOR04 --hb $COLOR0A --hf $COLOR0A --sb $COLOR02 --sf $COLOR0A --scb $COLOR00 --scf $COLOR0E \"" >> "$BEMENUOPTS_FILE"
echo "export BEMENU_OPTS=\"-H $HEIGHT --tb $COLOR00 --tf $COLOR0A --fb $COLOR00 --ff $COLOR09 --nb $COLOR02 --nf $COLOR0A --hb $COLOR06 --hf $COLOR06 --sb $COLOR01 --sf $COLOR06 \"" >> "$BEMENUOPTS_FILE"

View File

@ -57,7 +57,7 @@ compress() {
extract() { extract() {
set -f set -f
FILE="$(echo "$1" | xargs)" #use xargs to trim whitespace FILE="$(echo "$1" | xargs -0)" #use xargs to trim whitespace
DIR="$(basename "$FILE" | cut -f 1 -d '.')" DIR="$(basename "$FILE" | cut -f 1 -d '.')"
mkdir "$DIR" mkdir "$DIR"
case $FILE in case $FILE in
@ -65,7 +65,7 @@ extract() {
*.tar.gz|*.tgz) tar xzvf "$FILE" --directory="$DIR";; *.tar.gz|*.tgz) tar xzvf "$FILE" --directory="$DIR";;
*.tar.xz|*.txz) tar xJvf "$FILE" --directory="$DIR";; *.tar.xz|*.txz) tar xJvf "$FILE" --directory="$DIR";;
*.zip) unzip "$FILE" -d "$DIR";; *.zip) unzip "$FILE" -d "$DIR";;
*.rar) unrar x "$FILE" "$DIR";; *.rar) unrar-free -x "$FILE" "$DIR";;
*.7z | *.crx) 7z x "$FILE" -o"$DIR";; *.7z | *.crx) 7z x "$FILE" -o"$DIR";;
esac esac
} }

View File

@ -1,7 +1,7 @@
pkgname="ajh-base" pkgname="ajh-base"
pkgver="1.0.0" pkgver="1.0.0"
pkgver="1" pkgver="1"
pkgrel="9" pkgrel="10"
pkgdesc="Install my config for Arch based systems." pkgdesc="Install my config for Arch based systems."
arch=("any") arch=("any")
@ -20,7 +20,6 @@ depends=(
"fuse" "fuse"
"mesa" "mesa"
"libva-mesa-driver" "libva-mesa-driver"
"connman"
"brightnessctl" "brightnessctl"
"cifs-utils" "cifs-utils"
@ -72,6 +71,7 @@ depends=(
"archlinux-wallpaper" "archlinux-wallpaper"
#tui, terminal programs and programs/libs used by them #tui, terminal programs and programs/libs used by them
"tldr"
"imagemagick" "imagemagick"
"ffmpegthumbnailer" "ffmpegthumbnailer"
"python-pdftotext" "python-pdftotext"

View File

@ -8,10 +8,10 @@ sysrq-enabler
wlr-randr wlr-randr
sfeed sfeed
ani-cli-git ani-cli-git
connman-gtk
lf-sixel-git lf-sixel-git
autotiling autotiling
shellcheck-bin shellcheck-bin
pipe-viewer-git pipe-viewer-git
lobster lobster
systemd-boot-pacman-hook systemd-boot-pacman-hook
rofi-lbonn-wayland-only-git

View File

@ -0,0 +1,11 @@
[Match]
Name=enp3s0
[Network]
DHCP=yes
[DHCPv4]
RouteMetric=10
[IPv6AcceptRA]
RouteMetric=10

View File

@ -0,0 +1,11 @@
[Match]
Name=wlan0
[Network]
DHCP=yes
[DHCPv4]
RouteMetric=20
[IPv6AcceptRA]
RouteMetric=20

View File

@ -28,7 +28,7 @@ wireless() {
sudo systemctl enable tlp.service sudo systemctl enable tlp.service
sudo systemctl enable bluetooth.service sudo systemctl enable bluetooth.service
sudo systemctl enable connman.service #sudo systemctl enable connman.service
sudo systemctl enable iwd.service sudo systemctl enable iwd.service
echo "Done installing wireless programs." echo "Done installing wireless programs."
@ -81,7 +81,7 @@ configuration() {
chsh -s /bin/zsh "$USER" chsh -s /bin/zsh "$USER"
#setup .zprofile and zsh history file #setup .zprofile and zsh history file
ln -s ~/.profile ~/.zprofile ln -s ~/.config/zsh/.zprofile ~/.profile
mkdir -p ~/.cache/zsh mkdir -p ~/.cache/zsh
touch ~/.cache/zsh/history touch ~/.cache/zsh/history

View File

@ -0,0 +1,12 @@
#!/bin/sh
sudo pacman -S npm cargo
rm -rf ~/.config/nvim/
rm -rf ~/.local/share/nvim/
mkdir ~/.config/nvim
git clone https://github.com/NvChad/NvChad ~/.config/nvim --depth 1
rm -rf ~/.config/nvim/lua/custom/
ln -s ~/.config/nvchad/custom/ ~/.config/nvim/lua/

View File

@ -0,0 +1,16 @@
#!/bin/sh
echo "copying default systemd-networkd config files located in: "
echo " ../files/systemd/network/basic/ to: /etc/systemd/network/"
echo " modify these files if there is no internet connectivity."
echo " see available network devices (Name=*) with: ls /sys/class/net/"
sudo cp ../files/systemd/network/basic/* /etc/systemd/network/
sudo systemctl enable --now systemd-networkd.service
sudo systemctl enable --now systemd-resolved.service
#setup system to default to systemd-resolved config
sudo ln -rsf /run/systemd/resolve/stub-resolv.conf /etc/resolv.conf

View File

@ -0,0 +1,32 @@
#!/bin/sh
sudo dnf install https://mirrors.rpmfusion.org/free/fedora/rpmfusion-free-release-"$(rpm -E %fedora)".noarch.rpm https://mirrors.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-"$(rpm -E %fedora)".noarch.rpm
sudo dnf copr enable pennbauman/ports
sudo dnf install lf mpv ncmpcpp yt-dlp yt-dlp-zsh-completion chafa imv neovim p7zip
sudo dnf install htop radeontop
sudo dnf install mpd --allowerasing
#background stuff needed for scripts, etc.
sudo dnf install ImageMagick bat ffmpegthumbnailer
#gui programs
sudo dnf install zathura zathura-cb zathura-djvu zathura-pdf-mupdf
#misc
sudo dnf install foot-terminfo iputils
#development stuff
sudo dnf install git python3-pip g++
sudo dnf groupinstall "Development Tools" "Development Libraries"
sudo dnf install man-db
sudo dnf install rofi-wayland
sudo dnf copr enable derisis13/ani-cli
sudo dnf install ani-cli
sudo dnf install p7zip p7zip-plugins unrar-free

View File

@ -5,7 +5,7 @@ setwp() {
#wal -n -s -t -e -i "$1" #wal -n -s -t -e -i "$1"
rm ~/.config/wall rm ~/.config/wall
cp "$1" "$HOME/.config/wall" cp "$1" "$HOME/.config/wall"
swaymsg "output * bg ~/.config/wall fit" swaymsg "output * bg ~/.config/wall fill"
#swaybg --image "$HOME/.config/wall" #swaybg --image "$HOME/.config/wall"
} }

View File

@ -22,6 +22,8 @@ MAIL_DIR="$HOME/.local/share/mail"
SEP=" | " SEP=" | "
BATTERY_DEV="$(ls /sys/class/power_supply | grep -v AC | head -n1 )"
ddate () { ddate () {
printf " %s\n" "$(date "+%b %d, %Y ( %I:%M )")" #(%a) printf " %s\n" "$(date "+%b %d, %Y ( %I:%M )")" #(%a)
} }
@ -35,7 +37,7 @@ audio () {
# icon="$(echo "$volstat" | grep -o "\[[0-9]\+%\]" | sed 's/[^0-9]*//g' | sed -n 1p -) 🔊" # icon="$(echo "$volstat" | grep -o "\[[0-9]\+%\]" | sed 's/[^0-9]*//g' | sed -n 1p -) 🔊"
# fi # fi
icon="$(vol.sh -g) 🔊" icon="$(~/.local/scripts/vol.sh -g) 🔊"
[ "$(pamixer --get-mute)" = "true" ] && icon="🔇" [ "$(pamixer --get-mute)" = "true" ] && icon="🔇"
printf "%s\n" "$icon" printf "%s\n" "$icon"
@ -73,7 +75,7 @@ netup() {
if [ "$(echo "$iface" | grep w)" ]; then if [ "$(echo "$iface" | grep w)" ]; then
icon=" " icon=" "
else else
icon="" icon="🖧"
fi fi
elif [ -z "$icon" ]; then elif [ -z "$icon" ]; then
icon="❗" icon="❗"
@ -100,7 +102,8 @@ cputemp() {
battery() { battery() {
#BATT_DIR="/sys/class/power_supply/BAT0" #BATT_DIR="/sys/class/power_supply/BAT0"
BATT_DIR="/sys/class/power_supply/cw2015-battery" BATT_DIR="/sys/class/power_supply/$BATTERY_DEV"
if [ -d "$BATT_DIR" ]; then if [ -d "$BATT_DIR" ]; then
status="$(cat "$BATT_DIR"/status)" status="$(cat "$BATT_DIR"/status)"
charge="$(cat "$BATT_DIR"/capacity)" charge="$(cat "$BATT_DIR"/capacity)"
@ -123,7 +126,7 @@ crypto() {
} }
update() { update() {
echo " $SEP$(battery)$SEP$(netup)$SEP$(audio)$SEP$(rss)$SEP$(weather)$SEP$(ddate) " echo " $SEP$(battery)$SEP$(cputemp)$SEP$(netup)$SEP$(audio)$SEP$(rss)$SEP$(weather)$SEP$(ddate) "
} }

1
unrar
View File

@ -6,7 +6,6 @@
# $2 -> archive file name ex: archive.rar # $2 -> archive file name ex: archive.rar
# $3 -> (optional) directory to extract to # $3 -> (optional) directory to extract to
if [ "$1" = "x" ]; then if [ "$1" = "x" ]; then
if [ "$(echo "$2" | grep ".rar" )" ]; then if [ "$(echo "$2" | grep ".rar" )" ]; then
if [ -d "$3" ]; then if [ -d "$3" ]; then