Update rsync-local-config to send fonts as well

Fonts are copied to default GTK font directory
This commit is contained in:
Evie Litherland-Smith 2024-03-18 10:03:48 +00:00
parent 23c2eb48fb
commit dbf419d520

View file

@ -1,4 +1,5 @@
HOST=$1
# Config files
for TARGET in bat bottom git zellij starship.toml; do
SOURCE="$HOME/.config/$TARGET"
echo "--- $SOURCE ---"
@ -12,10 +13,13 @@ for TARGET in bat bottom git zellij starship.toml; do
TMP_SOURCE=$TMP_SOURCE/
NIX_REPLACE="fd -g '**' $TMP_TARGET -tfile -x $NIX_SED {};"
fi
rsync -avzL --exclude=".git*" "$SOURCE" $TMP_TARGET
chmod u+rw -R $TMP_SOURCE
rsync -avzL --exclude=".git*" --chmod=Du=rwx,Dg=rx,Do=rx,Fu=rw,Fg=r,Fo=r "$SOURCE" $TMP_TARGET
sh -c "$NIX_REPLACE"
rsync -avzL --delete --exclude=".git*" $TMP_SOURCE "$HOST:.config/$TARGET"
rm -rf $TMP_SOURCE
fi
done
# Fonts
rsync -avzL --delete --exclude=".git*" --chmod=Du=rwx,Dg=rx,Do=rx,Fu=rw,Fg=r,Fo=r "$(nix path-info flake:iosevka#packages.x86_64-linux.iosevka-custom-nerdfont)/share/fonts/truetype/" "$HOST:.fonts/IosevkaCustomNerdFont"
rsync -avzL --delete --exclude=".git*" --chmod=Du=rwx,Dg=rx,Do=rx,Fu=rw,Fg=r,Fo=r "$(nix path-info flake:iosevka#packages.x86_64-linux.iosevka-custom-aile)/share/fonts/truetype/" "$HOST:.fonts/IosevkaCustomAile"