Now have accurate version information built into jquery.js - will build it into the...
authorJohn Resig <jeresig@gmail.com>
Tue, 10 Oct 2006 00:23:18 +0000 (00:23 +0000)
committerJohn Resig <jeresig@gmail.com>
Tue, 10 Oct 2006 00:23:18 +0000 (00:23 +0000)
Makefile
build/docs/docs.js
src/jquery/jquery.js
version.txt [new file with mode: 0644]

index 45453f6..a906d0b 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -17,6 +17,9 @@ JQ = ${DIST_DIR}/jquery.js
 JQ_LITE = ${DIST_DIR}/jquery.lite.js
 JQ_PACK = ${DIST_DIR}/jquery.pack.js
 
+JQ_VER = `cat version.txt`
+VER = sed s/@VERSION/${JQ_VER}/
+
 JAR = java -jar ${BUILD_DIR}/js.jar
 
 all: jquery lite pack docs test
@@ -31,7 +34,7 @@ ${JQ}: ${MODULES}
        @@echo "Building" ${JQ}
 
        @@mkdir -p ${DIST_DIR}
-       @@cat ${MODULES} > ${JQ};
+       @@cat ${MODULES} | ${VER} > ${JQ};
 
        @@echo ${JQ} "Built"
        @@echo
index 8f331ea..500b91c 100644 (file)
@@ -17,7 +17,7 @@ function output( c, n ) {
        Object.toXML.force = { desc: 1, code: 1, before: 1, result: 1 };
        
        var xml = Object.toXML( n == "docs" ? { method: c } : c, "docs" );
-       
+
        writeFile( dir + "/data/jquery-" + n + "-xml.xml", 
                "<?xml version='1.0' encoding='ISO-8859-1'?>\n" + xml );
 
index 341bd88..ab7564f 100644 (file)
@@ -1,5 +1,5 @@
 /*\r
- * jQuery - New Wave Javascript\r
+ * jQuery @VERSION - New Wave Javascript\r
  *\r
  * Copyright (c) 2006 John Resig (jquery.com)\r
  * Dual licensed under the MIT (MIT-LICENSE.txt)\r
@@ -190,7 +190,7 @@ var $ = jQuery;
 \r
 jQuery.fn = jQuery.prototype = {\r
        /**\r
-        * The current SVN version of jQuery.\r
+        * The current version of jQuery.\r
         *\r
         * @private\r
         * @property\r
@@ -198,7 +198,7 @@ jQuery.fn = jQuery.prototype = {
         * @type String\r
         * @cat Core\r
         */\r
-       jquery: "$Rev$",\r
+       jquery: "@VERSION",\r
 \r
        /**\r
         * The number of elements currently matched.\r
diff --git a/version.txt b/version.txt
new file mode 100644 (file)
index 0000000..6d7de6e
--- /dev/null
@@ -0,0 +1 @@
+1.0.2