Add exception for docs project 44/39444/2
authorThanh Ha <thanh.ha@linuxfoundation.org>
Wed, 25 May 2016 19:54:09 +0000 (15:54 -0400)
committerThanh Ha <thanh.ha@linuxfoundation.org>
Wed, 25 May 2016 20:53:31 +0000 (16:53 -0400)
The docs project cannot be a submodule of itself.

Change-Id: I86a1303115be9eed9c3aa02ea7679e5285652307
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
jjb/docs/docs-rtd.yaml

index c5a8dd7eadd9b1265127a7c5bc8a971a946a96ba..01554ad078f08d92d62a1e7f4d471ec99dfa802a 100644 (file)
 
     builders:
         - shell: |
-            cd docs/submodules/$GERRIT_PROJECT
-            git fetch origin $GERRIT_REFSPEC && git checkout FETCH_HEAD
+            if [ "$GERRIT_PROJECT" != "docs" ]; then
+                cd docs/submodules/$GERRIT_PROJECT
+                git fetch origin $GERRIT_REFSPEC && git checkout FETCH_HEAD
+            else
+                git fetch origin $GERRIT_REFSPEC && git checkout FETCH_HEAD
+            fi
         - shell: |
             virtualenv $WORKSPACE/venv
             source $WORKSPACE/venv/bin/activate