Permalink
Browse files

adding comment header to compressed file, removing google advanced co…

…mpression as it was adding an f global var equal to false (why global cc?)
  • Loading branch information...
fabiomcosta committed Jun 5, 2011
1 parent bf78c7e commit 08d78380b77b6793c9e54331f8c8119fd83e8cb5
Showing with 8 additions and 6 deletions.
  1. +1 −0 HEADER
  2. +3 −1 Makefile
  3. +4 −4 dist/uSelector.js
  4. +0 −1 src/uSelector.js
View
1 HEADER
@@ -0,0 +1 @@
+/* author: Fabio Miranda Costa | github: fabiomcosta | twitter: @fabiomiranda | license: MIT-style license */
View
@@ -10,6 +10,8 @@ build: compress
@cd dist;\
rm $$(ls | egrep -v $$(ls -S | tail -1));\
mv * ${MODULE_NAME}.js;\
+ echo "Adding comment header to compressed file";\
+ cat ../HEADER ${MODULE_NAME}.js > __tmp__ && cat __tmp__ > ${MODULE_NAME}.js && rm -rf __tmp__;\
echo "Resulting file has `ls -lh *.js | tail -1 | awk '{ print $$5 }'`.";\
gzip -c ${MODULE_NAME}.js > ${MODULE_NAME}.js.gzip;\
echo "Resulting file gzipped has `ls -lh *.gzip | tail -1 | awk '{ print $$5 }'`.";\
@@ -26,7 +28,7 @@ compress:
fi;\
cat $$MODULES > ${UNCOMPRESSED}
@echo "Compressing with google compiler..."
- @java -jar assets/compiler.jar --jscomp_warning undefinedVars --charset utf8 --compilation_level ADVANCED_OPTIMIZATIONS --js ${UNCOMPRESSED} --js_output_file dist/${MODULE_NAME}.cc.js
+ @java -jar assets/compiler.jar --jscomp_warning undefinedVars --charset utf8 --compilation_level SIMPLE_OPTIMIZATIONS --js ${UNCOMPRESSED} --js_output_file dist/${MODULE_NAME}.cc.js
@echo "Compressing with yui compressor..."
@java -jar assets/yui.jar ${UNCOMPRESSED} -o dist/${MODULE_NAME}.yui.js --charset=utf8
@echo "Compressing with uglify..."
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View
@@ -2,7 +2,6 @@
* author: Fabio Miranda Costa
* github: fabiomcosta
* twitter: @fabiomiranda
- * website: http://meiocodigo.com
* license: MIT-style license
*/

0 comments on commit 08d7838

Please sign in to comment.