mirror of
https://github.com/Hopiu/jquery-mobile.git
synced 2026-03-16 22:10:25 +00:00
Changed js and css targets to use r.js and r-jqm.js
This commit is contained in:
parent
6efb8eb9b2
commit
0ed067ac0e
1 changed files with 17 additions and 17 deletions
34
Makefile
34
Makefile
|
|
@ -72,6 +72,10 @@ STRUCTURE = jquery.mobile.structure
|
|||
deploy: NAME = jquery.mobile-${VER_OFFICIAL}
|
||||
deploy: STRUCTURE = jquery.mobile.structure-${VER_OFFICIAL}
|
||||
|
||||
#Wrapper
|
||||
WRAP_START = "(function( $$, undefined ) {"
|
||||
WRAP_END = "}( jQuery ));"
|
||||
|
||||
# The CSS theme being used
|
||||
THEME = default
|
||||
|
||||
|
|
@ -88,17 +92,14 @@ all: init css js zip notify
|
|||
# Build and minify the CSS files
|
||||
css: init
|
||||
# Build the CSS file with the theme included
|
||||
@@node js/r.js -o cssIn=css/themes/default/jquery.mobile.theme.css out=${OUTPUT}/${NAME}.tmp.css
|
||||
@@cat LICENSE-INFO.txt | ${VER} > ${OUTPUT}/${NAME}.css
|
||||
@@cat ${CSSTHEMEFILES} ${CSSFILES} >> ${OUTPUT}/${NAME}.css
|
||||
# ..... and then minify it
|
||||
@@cat ${OUTPUT}/${NAME}.tmp.css >> ${OUTPUT}/${NAME}.css
|
||||
@@rm ${OUTPUT}/${NAME}.tmp.css
|
||||
@@node js/r.js -o cssIn=css/themes/default/jquery.mobile.theme.css optimizeCss=standard out=${OUTPUT}/${NAME}.tmp.min.css
|
||||
@@echo ${VER_MIN} > ${OUTPUT}/${NAME}.min.css
|
||||
@@java -jar build/yuicompressor-2.4.6.jar --type css ${OUTPUT}/${NAME}.css >> ${OUTPUT}/${NAME}.min.css
|
||||
# Build the CSS Structure-only file
|
||||
@@cat LICENSE-INFO.txt | ${VER} > ${OUTPUT}/${STRUCTURE}.css
|
||||
@@cat ${CSSFILES} >> ${OUTPUT}/${STRUCTURE}.css
|
||||
# ..... and then minify it
|
||||
@@echo ${VER_MIN} > ${OUTPUT}/${STRUCTURE}.min.css
|
||||
@@java -jar build/yuicompressor-2.4.6.jar --type css ${OUTPUT}/${STRUCTURE}.css >> ${OUTPUT}/${STRUCTURE}.min.css
|
||||
@@cat ${OUTPUT}/${NAME}.tmp.min.css >> ${OUTPUT}/${NAME}.min.css
|
||||
@@rm ${OUTPUT}/${NAME}.tmp.min.css
|
||||
# ..... and then copy in the images
|
||||
@@cp -R css/themes/${THEME}/images ${OUTPUT}/
|
||||
# Css portion is complete.
|
||||
|
|
@ -136,16 +137,15 @@ init:
|
|||
# Build and minify the JS files
|
||||
js: init
|
||||
# Build the JavaScript file
|
||||
@@node js/r-jqm.js -o baseUrl="js" include=jquery.mobile exclude=jquery,order out=${OUTPUT}/${NAME}.tmp.js wrap.start=${WRAP_START} wrap.end=${WRAP_END} optimize=none
|
||||
@@cat LICENSE-INFO.txt | ${VER} > ${OUTPUT}/${NAME}.js
|
||||
@@cat ${JSFILES} >> ${OUTPUT}/${NAME}.js
|
||||
# ..... and then minify it
|
||||
@@echo ${VER_MIN} > ${OUTPUT}/${NAME}.min.js
|
||||
@@java -XX:ReservedCodeCacheSize=64m \
|
||||
-jar build/google-compiler-20111003.jar \
|
||||
--js ${OUTPUT}/${NAME}.js \
|
||||
--js_output_file ${OUTPUT}/${NAME}.tmp.js
|
||||
@@cat ${OUTPUT}/${NAME}.tmp.js >> ${OUTPUT}/${NAME}.min.js
|
||||
@@cat ${OUTPUT}/${NAME}.tmp.js | sed "s/'order!/'/g" >> ${OUTPUT}/${NAME}.js
|
||||
@@rm ${OUTPUT}/${NAME}.tmp.js
|
||||
# Build the minified JavaScript file
|
||||
@@node js/r-jqm.js -o baseUrl="js" include=jquery.mobile exclude=jquery,order out=${OUTPUT}/${NAME}.tmp.min.js wrap.start=${WRAP_START} wrap.end=${WRAP_END} optimize=uglify
|
||||
@@echo ${VER_MIN} > ${OUTPUT}/${NAME}.min.js
|
||||
@@cat ${OUTPUT}/${NAME}.tmp.min.js | sed "s/'order!/'/g" >> ${OUTPUT}/${NAME}.min.js
|
||||
@@rm ${OUTPUT}/${NAME}.tmp.min.js
|
||||
# -------------------------------------------------
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue