X-Git-Url: https://arthur.barton.de/gitweb/?p=ax-zsh.git;a=blobdiff_plain;f=install.sh;h=cf290b464a463f0e1b462ff16c170bccad801504;hp=922f1a98c2b8bfd0391bf3e41949d31246a37e6f;hb=7228c618f80ebee4956fc52247651ab0eb583673;hpb=f59153717abf80de1ceeca9687d4aff83b017559 diff --git a/install.sh b/install.sh index 922f1a9..cf290b4 100755 --- a/install.sh +++ b/install.sh @@ -38,12 +38,10 @@ export AXZSH S=$(dirname "$0") -if [ "$S" = "$AXZSH" -o "$PWD" = "$AXZSH" ]; then +if [ "$S" = "$AXZSH" ] || [ "$PWD" = "$AXZSH" ] || [ -L "$AXZSH" ]; then ax_msg 1 "Initializing \"$AXZSH\":" else ax_msg 1 "Install AX-ZSH into \"$AXZSH\":" - - [ -L "$AXZSH" ] && rm -f "$AXZSH" mkdir -p "$AXZSH" || abort ax_msg - "Copying binaries and scripts ..." @@ -64,6 +62,14 @@ else cp -pR "$S/$p" "$AXZSH/$p" || abort done done + + ax_msg - "Copying themes ..." + mkdir -p "$AXZSH/themes" || abort + for p in "$S/themes/"*; do + echo "$p -> $AXZSH/$p" + rm -fr "${AXZSH:?}/$p" || abort + cp -pR "$S/$p" "$AXZSH/$p" || abort + done fi mkdir -p "$AXZSH/custom_plugins" || abort