blob: 1bf7645590a2b5fd4daa3f62b13d7a9394b7bfb0 [file] [log] [blame]
#!/bin/bash
# -----------------------------------------------------------------------------
# Validates that no pom versions contain SNAPSHOT.
# -----------------------------------------------------------------------------
[ ! -d "$ONOS_ROOT" ] && echo "ONOS_ROOT is not defined" >&2 && exit 1
aux=/tmp/pom-$$.log
trap "rm -f $aux 2>/dev/null" EXIT
grep -r SNAPSHOT . | \
grep -v -f $(dirname $0)/onos-validate-change-version.excludes > $aux
[ ! -s $aux ] && echo "There are files containing SNAPSHOT references:" && \
cat $aux && exit 1
exit 0