UNPKG

1.78 kBPlain TextView Raw
1# CodeGradXagent
2
3work : lint tests
4clean :
5 -rm -f .fw4ex.json [0-9]*ml
6
7# ############## Working rules:
8
9lint :
10 jshint codegradxagent.js spec/*.js
11
12tests : clean spec/oefgc.tgz
13# ./codegradxagent.js -h
14 -rm .fw4ex.json [0-9]*ml
15 jasmine
16
17reset :
18 npm install -g codegradxlib
19 npm link codegradxlib
20
21refresh :
22 cp -p ../CodeGradXlib/codegradxlib.js \
23 node_modules/codegradxlib/
24
25test-all :
26 cd ../CodeGradXlib/ && m tests
27 cd ../CodeGradXagent/ && m tests
28
29spec/oefgc.tgz :
30 cp -p ../CodeGradXlib/spec/oefgc.tgz spec/
31spec/org.example.fw4ex.bad.check.tgz :
32 cd spec; tar czf org.example.fw4ex.bad.check.tgz \
33 -C org.example.fw4ex.bad.check .
34
35# ############## NPM package
36# Caution: npm takes the whole directory that is . and not the sole
37# content of CodeGradXagent.tgz
38
39publish : clean
40 -rm -rf node_modules/codegradx*
41 npm install -S codegradxlib
42 git status .
43 -git commit -m "NPM publication `date`" .
44 git push
45 -rm -f CodeGradXagent.tgz
46 m CodeGradXagent.tgz install
47 cd tmp/CodeGradXagent/ && npm version patch && npm publish
48 cp -pf tmp/CodeGradXagent/package.json .
49 rm -rf tmp
50 npm install -g codegradxagent
51
52CodeGradXagent.tgz : clean
53 -rm -rf tmp
54 mkdir -p tmp
55 cd tmp/ && git clone https://github.com/ChristianQueinnec/CodeGradXagent.git
56 rm -rf tmp/CodeGradXagent/.git
57 cp -p package.json tmp/CodeGradXagent/
58 tar czf CodeGradXagent.tgz -C tmp CodeGradXagent
59 tar tzf CodeGradXagent.tgz
60
61REMOTE = www.paracamplus.com
62install : CodeGradXagent.tgz
63 rsync -avu CodeGradXagent.tgz \
64 ${REMOTE}:/var/www/www.paracamplus.com/Resources/Javascript/
65
66# ############## Various experiments (not all finished)
67
68README.tex : README.md
69 pandoc -o README.tex -f markdown README.md
70README.pdf : README.md
71 pandoc -o README.pdf -f markdown README.md
72
73# end of Makefile