diff options
author | Kris Moore <kris@pcbsd.org> | 2016-08-05 15:34:28 -0400 |
---|---|---|
committer | Kris Moore <kris@pcbsd.org> | 2016-08-05 15:34:28 -0400 |
commit | d62c1aad0c283a1aa6ac88c2bc09ed7cb961f6db (patch) | |
tree | 0781843b67729199567557e32c22e003795cf1c9 | |
parent | Add mkport.sh and port-files-master so we can automate building latest (diff) | |
download | lumina-d62c1aad0c283a1aa6ac88c2bc09ed7cb961f6db.tar.gz lumina-d62c1aad0c283a1aa6ac88c2bc09ed7cb961f6db.tar.bz2 lumina-d62c1aad0c283a1aa6ac88c2bc09ed7cb961f6db.zip |
Update mkport.sh
-rwxr-xr-x | mkport.sh | 23 |
1 files changed, 4 insertions, 19 deletions
@@ -6,24 +6,6 @@ port="x11/lumina" dfile="lumina" -which jq 2>/dev/null >/dev/null -if [ $? -ne 0 ] ; then - echo "Requires jq to be installed!" - exit 1 -fi - - -GITHUB_ORGANIZATION_NAME="trueos"; -REPO_NAME="trueos-core"; -COMMIT_SHA=$( fetch -o - https://api.github.com/repos/${GITHUB_ORGANIZATION_NAME}/${REPO_NAME}/commits/master 2>/dev/null | jq '.sha' | sed 's/"//g'); - -if [ -z "$COMMIT_SHA" ] ; then - echo "Failed to get sha of trueos-core commit" - exit 1 -fi - -ghtag="$COMMIT_SHA" - massage_subdir() { cd "$1" if [ $? -ne 0 ] ; then @@ -85,6 +67,9 @@ if [ -n "$OBJS" ] ; then exit 1 fi +# Get the GIT tag +ghtag=`git log -n 1 . | grep '^commit ' | awk '{print $2}'` + # Get the version if [ -e "version" ] ; then verTag=$(cat version) @@ -99,7 +84,7 @@ rm ${distdir}/${dfile}-* 2>/dev/null if [ -d "${portsdir}/${port}" ] ; then rm -rf ${portsdir}/${port} 2>/dev/null fi -cp -r port-files-master ${portsdir}/${port} +cp -r port-files ${portsdir}/${port} # Set the version numbers sed -i '' "s|%%CHGVERSION%%|${verTag}|g" ${portsdir}/${port}/Makefile |