From 4a0536c120416cc9e65a71cc25083a92e74d49b6 Mon Sep 17 00:00:00 2001 From: PHO Date: Wed, 28 Sep 2011 01:16:40 +0900 Subject: [PATCH] improved "make push" --- cabal-package.mk | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/cabal-package.mk b/cabal-package.mk index 2363b98..572e5b6 100644 --- a/cabal-package.mk +++ b/cabal-package.mk @@ -112,19 +112,26 @@ fixme: lint: $(HLINT) . --report -push: doc ditz +push: push-repo push-ditz push-doc + +push-repo: if [ -d "_darcs" ]; then \ darcs push; \ elif [ -d ".git" ]; then \ git push --all && git push --tags; \ fi + +push-ditz: ditz + rsync -av --delete \ + dist/ditz/ \ + www@nem.cielonegro.org:static.cielonegro.org/htdocs/ditz/$(PKG_NAME) + +push-doc: doc if [ -d "dist/doc" ]; then \ rsync -av --delete \ dist/doc/html/$(PKG_NAME)/ \ www@nem.cielonegro.org:static.cielonegro.org/htdocs/doc/$(PKG_NAME); \ fi - rsync -av --delete \ - dist/ditz/ \ - www@nem.cielonegro.org:static.cielonegro.org/htdocs/ditz/$(PKG_NAME) -.PHONY: build build-hook setup-config setup-config-hook run clean clean-hook install doc sdist test lint push +.PHONY: build build-hook setup-config setup-config-hook run clean clean-hook \ + install doc sdist test lint push push-repo push-ditz push-doc -- 2.40.0