File tree Expand file tree Collapse file tree 3 files changed +35
-0
lines changed Expand file tree Collapse file tree 3 files changed +35
-0
lines changed Original file line number Diff line number Diff line change 2
2
* ~
3
3
/* .less
4
4
/* .css
5
+ tests /bootstrap
6
+ tests /tmp
Original file line number Diff line number Diff line change @@ -18,3 +18,7 @@ test results. Combine with a *test-name-glob* to selectively compile.
18
18
You can also run specific tests by passing in an argument that contains any
19
19
part of the test name.
20
20
21
+ ## bootstrap.sh
22
+
23
+ It's a syntetic test comparing lessc and lessphp output compiling twitter bootstrap;
24
+ see bootstrap.sh for details.
Original file line number Diff line number Diff line change
1
+ echo " This script clones twitter bootsrap, compiles it with lessc and lessphp,"
2
+ echo " cleans up results with csstidy, and outputs diff. To run it, you need to"
3
+ echo " have git, csstidy and lessc installed."
4
+
5
+ csstidy_params=" --allow_html_in_templates=false --compress_colors=false --compress_font-weight=false --discard_invalid_properties=false --lowercase_s=false --preserve_css=true --remove_bslash=false --remove_last\;=false --sort-properties=true --sort-selectors=true --timestamp=false --silent=true --merge_selectors=0 --case-properties=0 --optimize-shorthands=0 --template=high"
6
+
7
+ diff_params=" -b -u -t -B"
8
+
9
+ if [ ! -d ' tmp/' ]
10
+ then
11
+ mkdir tmp/
12
+ fi
13
+
14
+ if [ ! -d ' bootsrap/' ]
15
+ then
16
+ echo " >> Cloning bootstrap to bootstrap/"
17
+ git clone https://github.com/twitter/bootstrap
18
+ fi
19
+
20
+ echo " >> Lessc compilation"
21
+ lessc bootstrap/less/bootstrap.less tmp/bootstrap.lessc.css
22
+ echo " >> Lessphp compilation"
23
+ ../plessc bootstrap/less/bootstrap.less tmp/bootstrap.lessphp.csstidy
24
+ echo " >> Cleanup and convert"
25
+ csstidy tmp/bootstrap.lessc.css $csstidy_params tmp/bootstrap.lessc.clean.css
26
+ csstidy tmp/bootstrap.lessphp.css $csstidy_params tmp/bootstrap.lessphp.clean.css
27
+ echo " >> Doing diff"
28
+ diff $diff_params tmp/bootstrap.lessc.clean.css tmp/bootstrap.lessphp.clean.css > tmp/diff
29
+ cat tmp/diff
You can’t perform that action at this time.
0 commit comments