Commit 80943f9d authored by JC Brand's avatar JC Brand

Make sure that bundler also gets installed.

- Added a stamp file for bundler.
- We now specify binary paths for bundler and Sass.
- Added a step "watch" to watch the Sass files.
- Add map file for Sass/CSS
parent c2be6019
...@@ -21,6 +21,7 @@ Backbone.Overview ...@@ -21,6 +21,7 @@ Backbone.Overview
tags tags
stamp-npm stamp-npm
stamp-bower stamp-bower
stamp-bundler
# Sphinx # Sphinx
docs/html docs/html
......
...@@ -6,7 +6,8 @@ PHANTOMJS ?= ./node_modules/.bin/phantomjs ...@@ -6,7 +6,8 @@ PHANTOMJS ?= ./node_modules/.bin/phantomjs
SPHINXBUILD ?= ./bin/sphinx-build SPHINXBUILD ?= ./bin/sphinx-build
SPHINXOPTS = SPHINXOPTS =
PO2JSON ?= ./node_modules/.bin/po2json PO2JSON ?= ./node_modules/.bin/po2json
SASS ?= sass SASS ?= ./.bundle/bin/sass
BUNDLE ?= ./.bundle/bin/bundle
GRUNT ?= ./node_modules/.bin/grunt GRUNT ?= ./node_modules/.bin/grunt
HTTPSERVE ?= ./node_modules/.bin/http-server HTTPSERVE ?= ./node_modules/.bin/http-server
...@@ -15,31 +16,34 @@ ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) ./d ...@@ -15,31 +16,34 @@ ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) ./d
# the i18n builder cannot share the environment and doctrees with the others # the i18n builder cannot share the environment and doctrees with the others
I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) ./docs/source I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) ./docs/source
.PHONY: all help clean html epub changes linkcheck gettext po pot po2json merge release css minjs build .PHONY: all help clean html epub changes linkcheck gettext po pot po2json merge release css minjs build dev-ruby
all: dev
help: help:
@echo "Please use \`make <target>' where <target> is one of the following" @echo "Please use \`make <target>' where <target> is one of the following:"
@echo " build create minified builds containing converse.js and all its dependencies" @echo ""
@echo " changes make an overview of all changed/added/deprecated items added to the documentation" @echo " all A synonym for 'make dev'."
@echo " css generate CSS from the Sass files" @echo " build Create minified builds of converse.js and all its dependencies."
@echo " dev set up the development environment" @echo " changes Make an overview of all changed/added/deprecated items added to the documentation."
@echo " epub export the documentation to epub" @echo " css Generate CSS from the Sass files."
@echo " gettext make PO message catalogs of the documentation" @echo " cssmin Minify the CSS files."
@echo " html make standalone HTML files of the documentation" @echo " dev Set up the development environment. To force a fresh start, run 'make clean' first."
@echo " linkcheck check all documentation external links for integrity" @echo " epub Export the documentation to epub."
@echo " cssmin minify the CSS files" @echo " gettext Make PO message catalogs of the documentation."
@echo " po generate gettext PO files for each i18n language" @echo " html Make standalone HTML files of the documentation."
@echo " po2json generate JSON files from the language PO files" @echo " linkcheck Check all documentation external links for integrity."
@echo " pot generate a gettext POT file to be used for translations" @echo " po Generate gettext PO files for each i18n language."
@echo " release make a new minified release" @echo " po2json Generate JSON files from the language PO files."
@echo " serve serve this directory via a webserver on port 8000" @echo " pot Generate a gettext POT file to be used for translations."
@echo " release Make a new minified release."
@echo " serve Serve this directory via a webserver on port 8000."
@echo " watch Tells Sass to watch the .scss files for changes and then automatically update the CSS files."
all: dev
######################################################################## ########################################################################
## Miscellaneous ## Miscellaneous
serve: dev serve: stamp-npm
$(HTTPSERVE) -p 8000 $(HTTPSERVE) -p 8000
######################################################################## ########################################################################
...@@ -84,28 +88,34 @@ stamp-bower: stamp-npm bower.json ...@@ -84,28 +88,34 @@ stamp-bower: stamp-npm bower.json
$(BOWER) install $(BOWER) install
touch stamp-bower touch stamp-bower
stamp-bundler:
mkdir -p .bundle
gem install --user bundler --bindir .bundle/bin
$(BUNDLE) install --path .bundle --binstubs .bundle/bin
touch stamp-bundler
clean:: clean::
rm -f stamp-npm stamp-bower rm -f stamp-npm stamp-bower stamp-bundler
rm -rf node_modules components rm -rf node_modules components .bundle
dev: clean dev: stamp-bower stamp-bundler
npm install
$(BOWER) update;
bundle install --path=~/
######################################################################## ########################################################################
## Builds ## Builds
css:: css:: dev-ruby
$(SASS) sass/converse.scss > css/converse.css $(SASS) -I .bundle/bin sass/converse.scss css/converse.css
watch:: dev-ruby
$(SASS) --watch -I .bundle/bin sass/converse.scss:css/converse.css
jsmin: jsmin:
./node_modules/requirejs/bin/r.js -o src/build.js && ./node_modules/requirejs/bin/r.js -o src/build-no-locales-no-otr.js && ./node_modules/requirejs/bin/r.js -o src/build-no-otr.js && ./node_modules/requirejs/bin/r.js -o src/build-website.js ./node_modules/requirejs/bin/r.js -o src/build.js && ./node_modules/requirejs/bin/r.js -o src/build-no-locales-no-otr.js && ./node_modules/requirejs/bin/r.js -o src/build-no-otr.js && ./node_modules/requirejs/bin/r.js -o src/build-website.js
cssmin: cssmin: stamp-node
$(GRUNT) cssmin $(GRUNT) cssmin
build:: build:: stamp-node
$(GRUNT) jst $(GRUNT) jst
$(GRUNT) minify $(GRUNT) minify
......
...@@ -1260,3 +1260,5 @@ ...@@ -1260,3 +1260,5 @@
margin-left: 0; margin-left: 0;
cursor: n-resize; cursor: n-resize;
z-index: 20; } z-index: 20; }
/*# sourceMappingURL=converse.css.map */
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