Code Review
/
ci-management.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Update global-jjb to pull in CLM disable patch
[ci-management.git]
/
jjb
/
shell
/
make-tar.sh
diff --git
a/jjb/shell/make-tar.sh
b/jjb/shell/make-tar.sh
index
6d36f0a
..
bd282d5
100644
(file)
--- a/
jjb/shell/make-tar.sh
+++ b/
jjb/shell/make-tar.sh
@@
-14,34
+14,44
@@
# See the License for the specific language governing permissions and
# limitations under the License.
# See the License for the specific language governing permissions and
# limitations under the License.
-source $WORKSPACE/version.properties
-TAR_NAME="${PROJECT}-${VERSION}.tgz"
+sudo yum install -y dos2unix
+# shellcheck source="$WORKSPACE/version.properties" disable=SC1091
+dos2unix "${WORKSPACE}/version.properties"
+source "$WORKSPACE/version.properties"
TARDIR=$UPLOAD_FILES_PATH
set -e -u -x -o pipefail
TARDIR=$UPLOAD_FILES_PATH
set -e -u -x -o pipefail
-rm -fr
$TARDIR
-mkdir
$TARDIR
+rm -fr
"$TARDIR"
+mkdir
"$TARDIR"
if [ "$PROJECT" == "addon-onap" ]
then
# ONAP addon is special.
# Build the regional controller scripts tar ball
if [ "$PROJECT" == "addon-onap" ]
then
# ONAP addon is special.
# Build the regional controller scripts tar ball
- ARTIFACT_NAME="onap-amsterdam-regional-controller-master"
- echo "Making tar file ${TARDIR}/${ARTIFACT_NAME}.tgz"
+ ARTIFACT_NAME="onap-amsterdam-regional-controller-${STREAM}"
+ TAR_NAME="${ARTIFACT_NAME}-${VERSION}-SNAPSHOT.tgz"
+ echo "Making tar file ${TARDIR}/${TAR_NAME}"
cd ./src/regional_controller_scripts/
cd ./src/regional_controller_scripts/
- tar -cvzf
${TARDIR}/${ARTIFACT_NAME}.tgz
*
+ tar -cvzf
"${TARDIR}/${TAR_NAME}" --
*
# Build the ONAP VM scripts tar ball
# Build the ONAP VM scripts tar ball
- ARTIFACT_NAME="onap-amsterdam-VM-master"
- echo "Making tar file ${TARDIR}/${ARTIFACT_NAME}.tgz"
+ ARTIFACT_NAME="onap-amsterdam-VM-${STREAM}"
+ TAR_NAME="${ARTIFACT_NAME}-${VERSION}-SNAPSHOT.tgz"
+ echo "Making tar file ${TARDIR}/${TAR_NAME}"
cd ../onap_vm_scripts/
cd ../onap_vm_scripts/
- tar -cvzf
${TARDIR}/${ARTIFACT_NAME}.tgz
*
+ tar -cvzf
"${TARDIR}/${TAR_NAME}" --
*
else
else
+ if [ "$STREAM" == "master" ]
+ then
+ TAR_NAME="${PROJECT}-${VERSION}-SNAPSHOT.tgz"
+ else
+ TAR_NAME="${PROJECT}-${VERSION}-${STREAM}-SNAPSHOT.tgz"
+ fi
echo "Making tar file ${TARDIR}/${TAR_NAME}"
echo "Making tar file ${TARDIR}/${TAR_NAME}"
- tar -cvzf
${TARDIR}/${TAR_NAME}
*
+ tar -cvzf
"${TARDIR}/${TAR_NAME}" --
*
fi
fi
-set +u +x
\ No newline at end of file
+set +u +x