Skip to content

Commit

Permalink
Reorganize the makefile.
Browse files Browse the repository at this point in the history
Try to make it a bit easier to follow the makefile.
  • Loading branch information
markstory committed May 22, 2014
1 parent 1fb9eeb commit dfee8a0
Showing 1 changed file with 20 additions and 11 deletions.
31 changes: 20 additions & 11 deletions Makefile
Expand Up @@ -35,6 +35,18 @@ help:
@echo "All other tasks are not intended to be run directly."


test: install
vendor/bin/phpunit


# Utility target for checking required parameters
guard-%:
@if [ "$($*)" = '' ]; then \
echo "Missing required $* variable."; \
exit 1; \
fi;


# Download composer
composer.phar:
curl -sS https://getcomposer.org/installer | php
Expand All @@ -43,15 +55,9 @@ composer.phar:
install: composer.phar
php composer.phar install

test: install
vendor/bin/phpunit

guard-%:
@if [ "$($*)" = '' ]; then \
echo "Missing required $* variable."; \
exit 1; \
fi;

# Version bumping & tagging for CakePHP itself
# Update VERSION.txt to new version.
bump-version: guard-VERSION
@echo "Update VERSION.txt to $(VERSION)"
Expand All @@ -69,7 +75,9 @@ tag-release: guard-VERSION bump-version
git push $(REMOTE)
git push $(REMOTE) --tags

# Tasks for tagging the app skeletong and


# Tasks for tagging the app skeleton and
# creating a zipball of a fully built app skeleton.
.PHONY: clean tag-app build-app package

Expand All @@ -90,9 +98,6 @@ tag-app: guard-VERSION build/app
cd build/app && git push $(REMOTE)
cd build/app && git push $(REMOTE) --tags

# Easier to type alias for zip balls
package: tag-app dist/cakephp-$(VERSION).zip

dist/cakephp-$(VERSION).zip: composer.phar
@if [ ! -d dist ]; \
then \
Expand All @@ -106,6 +111,10 @@ dist/cakephp-$(VERSION).zip: composer.phar
@echo "Building zipball for $(VERSION)"
find build/app -not -path '*.git*' | zip dist/cakephp-$(VERSION).zip -@

# Easier to type alias for zip balls
package: tag-app dist/cakephp-$(VERSION).zip



# Tasks to publish zipballs to github.
.PHONY: publish release
Expand Down

0 comments on commit dfee8a0

Please sign in to comment.