Commit e2239966 authored by Hugh Davenport's avatar Hugh Davenport

Change checkscript to only get current patch

This stops jenkins complaining about patches that current patch depends
on but haven't been submitted yet.

Change-Id: I38baa7ebc3c6997984878ca4d22112b1da89f1f1
Signed-off-by: default avatarHugh Davenport <hugh@catalyst.net.nz>
parent bf587cc6
......@@ -10,36 +10,11 @@ imageoptim:
find . -iname '*.jpg' -exec jpegoptim -q -p --strip-all {} \;
find . -iname '*.jpeg' -exec jpegoptim -q -p --strip-all {} \;
branch := $(GERRIT_REFSPEC)
ifeq (, $(branch))
branch := $(shell bash -c "git branch | grep \* | sed -e 's/ *\* *//'" )
endif
upstream_remote := $(shell git remote -v | grep gitorious.org/mahara/mahara.git | grep fetch | awk '{ print $$1 }')
ifeq (, $(upstream_remote))
upstream_remote := origin
endif
ifeq ("(no branch)", "$(branch)")
remote := $(upstream_remote)
else
remote := $(shell bash -c "git config --get branch.$(branch).remote" )
endif
ifeq (".", "$(remote)")
remote := $(upstream_remote)
endif
ifeq ("", "$(remote)")
remote := $(upstream_remote)
endif
commitid := $(shell bash -c "git merge-base $(remote)/master HEAD")
minaccept:
@echo "Running minimum acceptance test..."
@find htdocs/ -type f -name "*.php" | xargs -n 1 -P 2 php -l > /dev/null && echo All good!
@find htdocs/ -type f -name "install.xml" -path "*/db/install.xml" | xargs -n 1 -P 2 xmllint --schema htdocs/lib/xmldb/xmldb.xsd --noout
@if git rev-parse --verify HEAD 2>/dev/null; then git diff-index -p -M --cached $(commitid) -- ; fi | test/coding-standard-check.pl
@if git rev-parse --verify HEAD 2>/dev/null; then git show HEAD ; fi | test/coding-standard-check.pl
push: minaccept
@echo "Pushing the change upstream..."
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment