Commit 818c56f0 authored by fat's avatar fat

rewrite makefile to make a bit more "efficient" + rebuild

parent 82a75834
...@@ -62,21 +62,46 @@ clean: ...@@ -62,21 +62,46 @@ clean:
# recess & uglifyjs are required # recess & uglifyjs are required
# #
bootstrap: bootstrap: bootstrap-img bootstrap-css bootstrap-js
mkdir -p bootstrap/img
mkdir -p bootstrap/css
#
# JS COMPILE
#
bootstrap-js: bootstrap/js/*.js
bootstrap/js/*.js: js/*.js
mkdir -p bootstrap/js mkdir -p bootstrap/js
cp img/* bootstrap/img/
./node_modules/.bin/recess --compile ${BOOTSTRAP_LESS} > bootstrap/css/bootstrap.css
./node_modules/.bin/recess --compress ${BOOTSTRAP_LESS} > bootstrap/css/bootstrap.min.css
./node_modules/.bin/recess --compile ${BOOTSTRAP_RESPONSIVE_LESS} > bootstrap/css/bootstrap-responsive.css
./node_modules/.bin/recess --compress ${BOOTSTRAP_RESPONSIVE_LESS} > bootstrap/css/bootstrap-responsive.min.css
cat js/bootstrap-transition.js js/bootstrap-alert.js js/bootstrap-button.js js/bootstrap-carousel.js js/bootstrap-collapse.js js/bootstrap-dropdown.js js/bootstrap-modal.js js/bootstrap-tooltip.js js/bootstrap-popover.js js/bootstrap-scrollspy.js js/bootstrap-tab.js js/bootstrap-typeahead.js js/bootstrap-affix.js > bootstrap/js/bootstrap.js cat js/bootstrap-transition.js js/bootstrap-alert.js js/bootstrap-button.js js/bootstrap-carousel.js js/bootstrap-collapse.js js/bootstrap-dropdown.js js/bootstrap-modal.js js/bootstrap-tooltip.js js/bootstrap-popover.js js/bootstrap-scrollspy.js js/bootstrap-tab.js js/bootstrap-typeahead.js js/bootstrap-affix.js > bootstrap/js/bootstrap.js
./node_modules/.bin/uglifyjs -nc bootstrap/js/bootstrap.js > bootstrap/js/bootstrap.min.tmp.js ./node_modules/.bin/uglifyjs -nc bootstrap/js/bootstrap.js > bootstrap/js/bootstrap.min.tmp.js
echo "/*!\n* Bootstrap.js by @fat & @mdo\n* Copyright 2012 Twitter, Inc.\n* http://www.apache.org/licenses/LICENSE-2.0.txt\n*/" > bootstrap/js/copyright.js echo "/*!\n* Bootstrap.js by @fat & @mdo\n* Copyright 2012 Twitter, Inc.\n* http://www.apache.org/licenses/LICENSE-2.0.txt\n*/" > bootstrap/js/copyright.js
cat bootstrap/js/copyright.js bootstrap/js/bootstrap.min.tmp.js > bootstrap/js/bootstrap.min.js cat bootstrap/js/copyright.js bootstrap/js/bootstrap.min.tmp.js > bootstrap/js/bootstrap.min.js
rm bootstrap/js/copyright.js bootstrap/js/bootstrap.min.tmp.js rm bootstrap/js/copyright.js bootstrap/js/bootstrap.min.tmp.js
#
# CSS COMPLILE
#
bootstrap-css: bootstrap/css/*.css
bootstrap/css/*.css: less/*.less
mkdir -p bootstrap/css
./node_modules/.bin/recess --compile ${BOOTSTRAP_LESS} > bootstrap/css/bootstrap.css
./node_modules/.bin/recess --compress ${BOOTSTRAP_LESS} > bootstrap/css/bootstrap.min.css
./node_modules/.bin/recess --compile ${BOOTSTRAP_RESPONSIVE_LESS} > bootstrap/css/bootstrap-responsive.css
./node_modules/.bin/recess --compress ${BOOTSTRAP_RESPONSIVE_LESS} > bootstrap/css/bootstrap-responsive.min.css
#
# IMAGES
#
bootstrap-img: bootstrap/img/*
bootstrap/img/*: img/*
mkdir -p bootstrap/img
cp img/* bootstrap/img/
# #
# MAKE FOR GH-PAGES 4 FAT & MDO ONLY (O_O ) # MAKE FOR GH-PAGES 4 FAT & MDO ONLY (O_O )
# #
...@@ -98,4 +123,4 @@ watch: ...@@ -98,4 +123,4 @@ watch:
watchr -e "watch('less/.*\.less') { system 'make' }" watchr -e "watch('less/.*\.less') { system 'make' }"
.PHONY: docs watch gh-pages .PHONY: docs watch gh-pages bootstrap-img bootstrap-css bootstrap-js
\ No newline at end of file \ No newline at end of file
...@@ -108,6 +108,7 @@ ...@@ -108,6 +108,7 @@
e = $.Event('slide', { e = $.Event('slide', {
relatedTarget: $next[0] relatedTarget: $next[0]
, direction: direction
}) })
if ($next.hasClass('active')) return if ($next.hasClass('active')) return
......
...@@ -369,6 +369,7 @@ ...@@ -369,6 +369,7 @@
e = $.Event('slide', { e = $.Event('slide', {
relatedTarget: $next[0] relatedTarget: $next[0]
, direction: direction
}) })
if ($next.hasClass('active')) return if ($next.hasClass('active')) return
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment