-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathcircle.yml
54 lines (45 loc) · 1.9 KB
/
circle.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
general:
branches:
ignore:
- gh-pages
machine:
node:
version: 0.10.0
dependencies:
pre:
#- wget -O selenium-server.jar http://selenium.googlecode.com/files/selenium-server-standalone-2.33.0.jar
#- nohup bash -c "java -jar selenium-server.jar &"
#- npm install soda
#- npm install mocha
- npm install jshint -g
- npm install -g git://github.com/kanreisa/flagdoc.git
test:
override:
#- mocha -R spec
- jshint flagrate.js
deployment:
gh-pages:
branch: master
commands:
- git checkout gh-pages
- git config --global user.email "[email protected]"
- git config --global user.name "Flagrate"
- git merge --no-ff -m "Merge branch 'master' into gh-pages by CicleCI" master
- git rm --ignore-unmatch flagrate.min.js
- wget -O compiler.tar.gz http://dl.google.com/closure-compiler/compiler-latest.tar.gz
- tar -xzvf compiler.tar.gz compiler.jar
- java -jar compiler.jar --compilation_level SIMPLE_OPTIMIZATIONS --js flagrate.js > flagrate.min.js
- git add flagrate.min.js
- git rm --ignore-unmatch flagrate.min.css
- curl -L -o yuicompressor.zip https://github.com/downloads/yui/yuicompressor/yuicompressor-2.4.7.zip
- unzip -p yuicompressor.zip yuicompressor-2.4.7/build/* > yuicompressor.jar
- java -jar yuicompressor.jar --type css flagrate.css > flagrate.min.css
- git add flagrate.min.css
- git commit -a -m "Build 'flagrate.min.js' and 'flagrate.min.css'" || true
- git rm -r --ignore-unmatch api
- mkdir api
- flagdoc --scripts=flagrate.js --readme=README.md --output=api/ --source-link-prefix=https://github.com/webnium/flagrate/blob/master/
- git add api
- git commit -a -m "Build API documentation" || true
- git push || true
#- rsync -rlptz --delete -e "ssh -p 10022" ./ [email protected]:~/www/