diff --git a/bin/entrypoint.sh b/bin/entrypoint.sh index 21f66d0ba8b1c35a2b753b966aa3ee8221a8613e..8a6254b676f15fa41a5e331a5344c604f41ca6c0 100755 --- a/bin/entrypoint.sh +++ b/bin/entrypoint.sh @@ -38,10 +38,15 @@ if [[ "$1" == *.ts || "$1" == *.js ]]; then if [ -f "$botFilePath" ]; then cd /bot && pwd + [ -f package.json ] && { echo "Install dependencies modules ..." yarn } + + echo "Linking Wechaty Module ... " + npm link + echo "Executing ts-node $botFilePath $@" ts-node "$botFilePath" $@ ret=$?