1
0
Fork 0
mirror of https://github.com/twbs/bootstrap.git synced 2022-11-09 12:25:43 -05:00
twbs--bootstrap/Makefile

37 lines
1 KiB
Makefile
Raw Normal View History

BOOTSTRAP = ./docs/assets/css/bootstrap.css
BOOTSTRAP_LESS = ./less/bootstrap.less
BOOTSTRAP_RESPONSIVE = ./docs/assets/css/bootstrap-responsive.css
BOOTSTRAP_RESPONSIVE_LESS = ./less/responsive.less
2012-01-24 14:37:57 -05:00
LESS_COMPRESSOR ?= `which lessc`
UGLIFY_JS ?= `which uglifyjs`
WATCHR ?= `which watchr`
2012-01-23 17:14:16 -05:00
#
# Build less files + docs
2012-01-23 17:14:16 -05:00
#
build:
@if test ! -z ${LESS_COMPRESSOR}; then \
lessc ${BOOTSTRAP_LESS} > ${BOOTSTRAP}; \
lessc ${BOOTSTRAP_RESPONSIVE_LESS} > ${BOOTSTRAP_RESPONSIVE}; \
node docs/build; \
cp img/* docs/assets/img/; \
else \
echo "You must have the LESS compiler installed in order to build Bootstrap."; \
echo "You can install it by running: npm install less -g"; \
fi
2012-01-23 17:14:16 -05:00
#
# Watch less files
#
watch:
@if test ! -z ${WATCHR}; then \
echo "Watching less files..."; \
watchr -e "watch('less/.*\.less') { system 'make' }"; \
else \
echo "You must have the watchr installed in order to watch Bootstrap Less files."; \
echo "You can install it by running: gem install watchr"; \
fi
.PHONY: build watch