Browse Source

do not push in PR from forks

Julius Pfrommer 7 years ago
parent
commit
02746b7625
2 changed files with 10 additions and 0 deletions
  1. 5 0
      tools/travis/travis_push_doc.sh
  2. 5 0
      tools/travis/travis_push_release.sh

+ 5 - 0
tools/travis/travis_push_doc.sh

@@ -1,6 +1,11 @@
 #!/bin/bash
 set -ev
 
+# The encrypted key is not available in pull requests from forks
+if [ -z "$GITAUTH" ]; then
+    exit 0
+fi
+
 git clone --depth=5 -b gh-pages https://$GITAUTH@github.com/open62541/open62541-www
 cd open62541-www
 

+ 5 - 0
tools/travis/travis_push_release.sh

@@ -7,6 +7,11 @@ BRANCH="$(git log --pretty=format:"%d" --date=iso --abbrev=10 --all -1)"
 DATE="$(git log --pretty=format:"%ad" --date=iso --abbrev=10 --all -1)"
 COMMENT="$(git log --pretty=format:"%s" --date=iso --abbrev=10 --all -1)"
 
+# The encrypted key is not available in pull requests from forks
+if [ -z "$GITAUTH" ]; then
+    exit 0
+fi
+
 git clone --depth=5 -b gh-pages https://$GITAUTH@github.com/open62541/open62541-www
 cd open62541-www