2014-11-01 12:45:17 +00:00
|
|
|
.PHONY: all gh-pages sf-files
|
|
|
|
|
|
|
|
.SUFFIXES:
|
|
|
|
|
|
|
|
all: gh-pages sf-files
|
|
|
|
|
|
|
|
GH_NAME = Oliver Schmidt
|
|
|
|
GH_MAIL = ol.sc@web.de
|
2014-11-03 20:23:29 +00:00
|
|
|
GH_PATH = ../doc
|
2014-11-01 12:45:17 +00:00
|
|
|
|
|
|
|
gh-pages:
|
|
|
|
ifdef GH_TOKEN
|
2014-11-03 20:23:29 +00:00
|
|
|
@echo 'git clone --branch=gh-pages https://$$(GH_TOKEN)@github.com/cc65/doc.git $(GH_PATH)'
|
|
|
|
@git clone --branch=gh-pages https://$(GH_TOKEN)@github.com/cc65/doc.git $(GH_PATH)
|
2014-11-01 12:45:17 +00:00
|
|
|
cd $(GH_PATH) && git config user.name "$(GH_NAME)"
|
|
|
|
cd $(GH_PATH) && git config user.email "$(GH_MAIL)"
|
|
|
|
cd $(GH_PATH) && git config push.default simple
|
2014-11-03 20:23:29 +00:00
|
|
|
$(RM) $(GH_PATH)/*.*
|
|
|
|
cp html/*.* $(GH_PATH)
|
|
|
|
cd $(GH_PATH) && git add -A
|
2014-11-01 12:45:17 +00:00
|
|
|
-cd $(GH_PATH) && git commit -m "Updated from commit $(TRAVIS_COMMIT)."
|
2014-11-03 22:31:54 +00:00
|
|
|
cd $(GH_PATH) && git push -q
|
2014-11-01 12:45:17 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
SF_USER = oliverschmidt
|
|
|
|
SF_HOST = frs.sourceforge.net
|
2015-01-20 20:00:44 +00:00
|
|
|
SF_FILE = /home/frs/project/cc65/cc65-snapshot-win32.zip
|
2014-11-01 12:45:17 +00:00
|
|
|
|
|
|
|
SCPFLAGS = -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -q
|
|
|
|
|
|
|
|
sf-files:
|
|
|
|
ifdef SF_PASS
|
|
|
|
echo $(TRAVIS_COMMIT) | zip -z cc65
|
|
|
|
@echo 'sshpass -p $$(SF_PASS) scp $(SCPFLAGS) cc65.zip $(SF_USER)@$(SF_HOST):$(SF_FILE)'
|
|
|
|
@sshpass -p $(SF_PASS) scp $(SCPFLAGS) cc65.zip $(SF_USER)@$(SF_HOST):$(SF_FILE)
|
|
|
|
endif
|