Skip to content

Commit 5cda9be

Browse files
author
Vladimir Kotal
committed
check for non empty pull request variable
1 parent c6fe452 commit 5cda9be

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

dev/docker.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,14 +55,14 @@ echo "Running the image in container"
5555
docker run -d $IMAGE
5656
docker ps -a
5757

58-
# Travis can only work on master since it needs encrypted variables.
59-
if [ "${OPENGROK_PULL_REQUEST}" != "false" ]; then
58+
# This can only work on home repository since it needs encrypted variables.
59+
if [[ -n "$OPENGROK_PULL_REQUEST" ]]; then
6060
echo "Not pushing Docker image for pull requests"
6161
exit 0
6262
fi
6363

6464
# The push only works on the main repository.
65-
if [[ "${OPENGROK_REPO_SLUG}" != "oracle/opengrok" ]]; then
65+
if [[ "$OPENGROK_REPO_SLUG" != "oracle/opengrok" ]]; then
6666
echo "Not pushing Docker image for non main repository"
6767
exit 0
6868
fi

0 commit comments

Comments
 (0)