Skip to content
This repository
Browse code

Fixes #3479

Added $.mobile.version
  • Loading branch information...
commit ae835d0af11e0e822933f127b82b19fbe84ee4de 1 parent b08ff1e
Ghislain Seguin authored January 25, 2012
7  Makefile
@@ -18,7 +18,7 @@ deploy: STRUCTURE = jquery.mobile.structure-${VER_OFFICIAL}
18 18
 # The CSS theme being used
19 19
 THEME = default
20 20
 
21  
-RUN_JS = @@java -XX:ReservedCodeCacheSize=64m -classpath build/js.jar:build/google-compiler-20111003.jar org.mozilla.javascript.tools.shell.Main
  21
+RUN_JS = @@/usr/local/bin/node
22 22
 
23 23
 
24 24
 
@@ -99,7 +99,8 @@ js: init
99 99
 	${RUN_JS} \
100 100
 		external/r.js/dist/r.js \
101 101
 	 	-o baseUrl="js" \
102  
-		include=jquery.mobile exclude=jquery,order \
  102
+		include=jquery.mobile \
  103
+		exclude=jquery,order,text,text!../version.txt \
103 104
 		out=${OUTPUT}/${NAME}.compiled.js \
104 105
 		pragmasOnSave.jqmBuildExclude=true \
105 106
 		wrap.startFile=build/wrap.start \
@@ -108,7 +109,7 @@ js: init
108 109
 		skipModuleInsertion=true \
109 110
 		optimize=none
110 111
 	@@cat LICENSE-INFO.txt | ${VER} > ${OUTPUT}/${NAME}.js
111  
-	@@cat ${OUTPUT}/${NAME}.compiled.js >> ${OUTPUT}/${NAME}.js
  112
+	@@cat ${OUTPUT}/${NAME}.compiled.js | sed 's/__version__/"${VER_OFFICIAL}"/g' >> ${OUTPUT}/${NAME}.js
112 113
 	@@rm ${OUTPUT}/${NAME}.compiled.js
113 114
 	# ..... and then minify it
114 115
 	@@echo ${VER_MIN} > ${OUTPUT}/${NAME}.min.js
4  js/jquery.mobile.core.js
@@ -4,7 +4,7 @@
4 4
 //>>group: core
5 5
 //>>required: true
6 6
 
7  
-define( [ "jquery", "./jquery.mobile.widget" ], function( $ ) {
  7
+define( [ "jquery", "text!../version.txt", "./jquery.mobile.widget" ], function( $, __version__ ) {
8 8
 //>>excludeEnd("jqmBuildExclude");
9 9
 (function( $, window, undefined ) {
10 10
 
@@ -13,6 +13,8 @@ define( [ "jquery", "./jquery.mobile.widget" ], function( $ ) {
13 13
 	// jQuery.mobile configurable options
14 14
 	$.mobile = $.extend( {}, {
15 15
 
  16
+		version: __version__,
  17
+
16 18
 		// Namespace used framework-wide for data-attrs. Default is no namespace
17 19
 		ns: "",
18 20
 

0 notes on commit ae835d0

Please sign in to comment.
Something went wrong with that request. Please try again.