From 95773e0623bc89debbd04e948dc88940709eecb5 Mon Sep 17 00:00:00 2001 From: peaceiris <30958501+peaceiris@users.noreply.github.com> Date: Sun, 26 May 2019 22:37:08 +0900 Subject: [PATCH] fix: shellcheck errors --- entrypoint.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/entrypoint.sh b/entrypoint.sh index c2cfe807f..93a1f2291 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -1,7 +1,7 @@ #!/bin/sh # setup ssh -if [[ -z "${ACTIONS_DEPLOY_KEY}" ]]; then +if [ -z "${ACTIONS_DEPLOY_KEY}" ]; then echo "error: not found ACTIONS_DEPLOY_KEY" exit 1 fi @@ -11,12 +11,12 @@ echo "${ACTIONS_DEPLOY_KEY}" > /root/.ssh/id_rsa chmod 400 /root/.ssh/id_rsa # push to gh-pages branch -if [[ -z "${PUBLISH_DIR}" ]]; then +if [ -z "${PUBLISH_DIR}" ]; then echo "error: not found PUBLISH_DIR" exit 1 fi -cd ${PUBLISH_DIR} -if [[ -z "${PUBLISH_BRANCH}" ]]; then +cd "${PUBLISH_DIR}" || exit 1 +if [ -z "${PUBLISH_BRANCH}" ]; then echo "error: not found PUBLISH_BRANCH" exit 1 fi