upload things to the right place
[haskell-report.git] / Makefile
1 VERSION = 2010
2
3 default:
4 cd tools && make
5 cd report && make
6
7 clean:
8 cd report && make clean
9 cd tools && make clean
10
11 release:
12 cd tools && make
13 cd report && make
14 mkdir haskell$(VERSION) || true
15 cp report/ht/*.html report/ht/*.png report/ht/*.css haskell$(VERSION)
16 tar cvzf haskell$(VERSION)-html.tar.gz haskell$(VERSION)
17
18 # If you have an account on www.haskell.org, the following rules will upload
19 # the finished report to the correct places.
20 UPLOAD_HOST = www.haskell.org
21 UPLOAD_HTML_DIR = /home/haskell/onlinereport/haskell$(VERSION)
22 UPLOAD_DEFN_DIR = /home/haskell/definition
23
24 upload:
25 ssh $(UPLOAD_HOST) "mkdir $(UPLOAD_HTML_DIR) || true"
26 ssh $(UPLOAD_HOST) "mkdir $(UPLOAD_DEFN_DIR) || true"
27 scp report/haskell.pdf $(UPLOAD_HOST):$(UPLOAD_DEFN_DIR)/haskell$(VERSION).pdf
28 scp haskell$(VERSION)-html.tar.gz $(UPLOAD_HOST):$(UPLOAD_DEFN_DIR)
29 ssh $(UPLOAD_HOST) "cd $(UPLOAD_HTML_DIR); tar xvzf $(UPLOAD_DEFN_DIR)/haskell$(VERSION)-html.tar.gz; mv haskell$(VERSION)/* .; rmdir haskell$(VERSION); rm -f index.html; ln -s haskell.html index.html"