You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

17 lines
381 B

#!/usr/bin/env sh
set -eu
ROOT_DIR="$(CDPATH= cd -- "$(dirname -- "$0")/.." && pwd)"
SRC_DIR="$ROOT_DIR/node_modules/vditor/dist"
DST_DIR="$ROOT_DIR/public/vditor/dist"
if [ ! -d "$SRC_DIR" ]; then
echo "skip sync: $SRC_DIR not found"
exit 0
fi
mkdir -p "$DST_DIR"
rm -rf "$DST_DIR"
mkdir -p "$DST_DIR"
cp -R "$SRC_DIR"/. "$DST_DIR"/
echo "synced vditor assets to $DST_DIR"