X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=tools%2Fhtdocs%2FMakefile;h=22e4d7cb14ba2bd0c7191265b8f971d1f1ae18b2;hb=792daf2373f2dd35eff60413d3cb7f5e5c1536b7;hp=b83d1d4249bc579b4fbefea043d5d7e96bef2bd8;hpb=2400b59299eb29407b14c1ba69649f5b9c9fc065;p=mkws-moved-to-github.git diff --git a/tools/htdocs/Makefile b/tools/htdocs/Makefile index b83d1d4..22e4d7c 100644 --- a/tools/htdocs/Makefile +++ b/tools/htdocs/Makefile @@ -1,104 +1,110 @@ -###################################################################### -# Copyright (c) 2013 IndexData ApS. http://indexdata.com -# - -############################## -# select a jquery version -# -#JQUERY_URL= http://code.jquery.com/jquery-2.0.3.min.js -JQUERY_URL= http://code.jquery.com/jquery-1.10.0.min.js -#JQUERY_URL= http://code.jquery.com/jquery-1.9.1.min.js -#JQUERY_URL= http://code.jquery.com/jquery-1.8.3.min.js -#JQUERY_URL= http://code.jquery.com/jquery-1.7.2.min.js -#JQUERY_URL= http://code.jquery.com/jquery-1.6.4.min.js -#JQUERY_URL= http://code.jquery.com/jquery-1.4.4.min.js - -JQUERY_UI_URL= http://code.jquery.com/ui/1.10.3/jquery-ui.js -#JQUERY_UI_URL= http://code.jquery.com/ui/1.8.0/jquery-ui.min.js -JQUERY_JSON_URL= https://jquery-json.googlecode.com/files/jquery.json-2.4.js - -MKWS_JS= mkws-complete.js -PZ2API_JS= ../../../pazpar2/js/pz2.js -PZ2API_GIT= ssh://git.indexdata.com:222/home/git/pub/pazpar2 -############################## -JQUERY_JSON_FILE := $(shell basename ${JQUERY_JSON_URL}) - -DOCS = README.html README.odt README.pdf \ - whitepaper.html whitepaper.odt whitepaper.pdf - -**default**: ${MKWS_JS} README.html whitepaper.html - -all: ${MKWS_JS} $(DOCS) - -docs: $(DOCS) - -pz2api-git-checkout: - @if ! test -e ${PZ2API_JS}; then \ - ( cd ../../.. && git clone ${PZ2API_GIT} ); \ - fi +# Copyright (c) 2013-2014 IndexData ApS. http://indexdata.com -mkws-js ${MKWS_JS}: mkws.js handlebars-v1.1.2.js ${JQUERY_JSON_FILE} - @if ! test -e ${PZ2API_JS}; then \ - echo "The pazpar2 JS file ${PZ2API_JS} does not exists."; \ - echo "Did you checked out the source from the git repo?"; \ - echo ""; \ - echo "Please run:"; \ - echo "$$ make pz2api-git-checkout"; \ - echo ""; \ - exit 1; \ - fi - ( echo "/* created at: $$(date)"; \ - echo " mkws.js GIT id: $$(git log mkws.js | head -n 1 | perl -npe 's,\S+\s+,,')"; \ - echo " $$(basename ${PZ2API_JS}) GIT id: $$(cd $$(dirname ${PZ2API_JS}) && git log $$(basename ${PZ2API_JS}) | head -n 1 | perl -npe 's,\S+\s+,,')"; \ - echo "*/"; \ - curl -sSf ${JQUERY_URL} | perl -npe 's,sourceMappingURL=jquery.*map,,'; \ - cat ${JQUERY_JSON_FILE}; \ - cat handlebars-v1.1.2.js; \ - cat ${PZ2API_JS}; \ - cat mkws.js ) > ${MKWS_JS}.new - mv -f ${MKWS_JS}.new ${MKWS_JS} +SRC= ../../src +VPATH= ${SRC} -handlebars-v1.1.2.js: - curl -sSf http://builds.handlebarsjs.com.s3.amazonaws.com/handlebars-v1.1.2.js -o $@ +HANDLEBARS_FILE = handlebars-v1.1.2.js +JQUERY_FILE = jquery-1.10.0.min.js +JQUERY_JSON_FILE = jquery.json-2.4.js +PP2_FILE = pz2.js -${JQUERY_JSON_FILE}: - curl -sSf ${JQUERY_JSON_URL} -o $@ +HANDLEBARS_URL = http://builds.handlebarsjs.com.s3.amazonaws.com/${HANDLEBARS_FILE} +JQUERY_URL = http://code.jquery.com/${JQUERY_FILE} +JQUERY_JSON_URL = https://jquery-json.googlecode.com/files/${JQUERY_JSON_FILE} +PP2_URL = http://git.indexdata.com/?p=pazpar2.git;a=blob_plain;f=js/${PP2_FILE};hb=HEAD +JQUERY_UI_URL = http://code.jquery.com/ui/1.10.3/jquery-ui.js +VERSION = $(shell tr -d '\012' < ${SRC}/VERSION) -# For a description of pandoc's markdown format, see: -# http://johnmacfarlane.net/pandoc/demo/example9/pandocs-markdown.html --> +COMPONENTS = mkws-handlebars.js \ + mkws-core.js mkws-team.js mkws-filter.js \ + mkws-widget.js mkws-widget-main.js mkws-widget-termlists.js \ + mkws-widget-authname.js mkws-widget-categories.js mkws-widget-log.js \ + mkws-widget-record.js mkws-widget-reference.js mkws-widget-builder.js -# for older pandoc (<1.9) run first: -# perl -i.bak -npe 's/"(Authors|Subjects)": "(.*?)"/"$1": "test"/' tools/htdocs/whitepaper.markdown -# -%.html: %.markdown - rm -f $@ - pandoc --standalone --toc -c mkws-doc.css $< | sed '/^