Skip to content

Commit 774d95c

Browse files
committed
Improved the deployment script a bit more
1 parent 34a09ff commit 774d95c

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

deploy.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,12 @@
22

33
set -e
44

5-
npm run build
5+
if [ -z "${1%@*}" ] || [ -z "${1#*@}" ]; then
6+
echo "Please specify a valid ssh connection! (user@host)" >&2
7+
exit 1
8+
fi
9+
10+
[ "$2" != "--skip-build" ] && [ "$2" != "-s" ] && npm run build
611

712
ssh "$1" /bin/sh <<'EOF'
813
set -e

0 commit comments

Comments
 (0)