move current_dir check in an earlier step of the script
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/branches/pmd/4.2.x@7247 51baf565-9d33-0410-a72c-fc3788e3496d
This commit is contained in:
parent
a3393f4b13
commit
3f39a04a58
@ -43,21 +43,17 @@ while getopts v:dsh OPT; do
|
||||
esac
|
||||
done
|
||||
|
||||
current_dir=$(pwd | sed -e 's/^.*\///')
|
||||
if [ "${current_dir}" != "etc" ]; then
|
||||
echo "release script MUST be executed from the 'etc' folder"
|
||||
exit 3
|
||||
fi
|
||||
|
||||
if [ -z ${version} ]; then
|
||||
check_dependency "xsltproc"
|
||||
readonly version=$(xsltproc extract_release_number.xslt ../pom.xml | grep VERSION | cut -f2 -d: | sed -e 's/-SNAPSHOT//')
|
||||
fi
|
||||
|
||||
check_dependency "ant"
|
||||
check_dependency "maven"
|
||||
check_dependency "mvn"
|
||||
|
||||
current_dir=$(pwd | sed -e 's/^.*\///')
|
||||
if [ "${current_dir}" -ne "etc" ], then
|
||||
echo "release script MUST be executed from the 'etc' folder"
|
||||
exit 3
|
||||
fi
|
||||
|
||||
echo "building release version ${version}"
|
||||
|
||||
pmd_top_dir="$(mktemp -d)"
|
||||
|
Loading…
x
Reference in New Issue
Block a user