pierventre | 80b532d | 2022-07-29 21:57:16 +0200 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | # ----------------------------------------------------------------------------- |
| 3 | # Uploads ONOS Java API docs. |
| 4 | # ----------------------------------------------------------------------------- |
| 5 | |
| 6 | set -e |
| 7 | |
| 8 | [ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1 |
| 9 | . $ONOS_ROOT/tools/build/envDefaults |
| 10 | |
| 11 | docs="bazel-bin/docs/external.jar" |
| 12 | docs_path="bazel-bin/docs/tmp" |
| 13 | mkdir -p ${docs_path} |
| 14 | |
| 15 | ONOS_VERSION_STRING=${ONOS_VERSION} |
| 16 | if echo ${ONOS_VERSION_STRING} | grep -- '-b'; then |
| 17 | echo "ONOS version ${ONOS_VERSION_STRING} is a beta. Skipping" |
| 18 | exit 0 |
| 19 | fi |
| 20 | |
| 21 | unzip ${docs} -d ${docs_path} |