Hagop Bozawglanian | 9328ffe | 2019-02-11 19:47:37 +0000 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | |
| 3 | set -e -o pipefail |
Hagop Bozawglanian | 0312958 | 2019-02-28 19:09:30 +0000 | [diff] [blame] | 4 | set -- $ARTIFACT_NAME |
| 5 | if [ -z "$ARTIFACT_NAME" ] |
| 6 | then |
| 7 | echo "ERROR NO ARTIFACTS ENTERED" |
| 8 | else |
| 9 | if [ -z "$2" ] |
| 10 | then |
| 11 | cd $WORKSPACE/docs/data |
| 12 | echo "-n --upload-file $ARTIFACT_NAME https://nexus.onap.org/content/sites/raw/$PROJECT_ID/$GERRIT_BRANCH/$ARTIFACT_NAME" |
| 13 | curl -n --upload-file "$ARTIFACT_NAME" "https://nexus.onap.org/content/sites/raw/$PROJECT_ID/$GERRIT_BRANCH/$ARTIFACT_NAME" |
| 14 | else |
| 15 | cd $WORKSPACE/ice_validator/output |
| 16 | echo "-n --upload-file $1 https://nexus.onap.org/content/sites/raw/$PROJECT_ID/$GERRIT_BRANCH/$1" |
| 17 | curl -n --upload-file "$1" "https://nexus.onap.org/content/sites/raw/$PROJECT_ID/$GERRIT_BRANCH/$1" |
| 18 | echo "-n --upload-file $2 https://nexus.onap.org/content/sites/raw/$PROJECT_ID/$GERRIT_BRANCH/$2" |
| 19 | curl -n --upload-file "$2" "https://nexus.onap.org/content/sites/raw/$PROJECT_ID/$GERRIT_BRANCH/$2" |
| 20 | fi |
| 21 | fi |