npm release
authoradam <adamansky@gmail.com>
Tue, 10 Sep 2013 16:13:25 +0000 (23:13 +0700)
committeradam <adamansky@gmail.com>
Tue, 10 Sep 2013 16:13:25 +0000 (23:13 +0700)
package.json
tools/release.sh

index ba0c384..7b319e1 100644 (file)
@@ -1,9 +1,9 @@
 {
     "name" : "ejdb",
-    "version" : "1.1.23",
+    "version" : "1.1.24",
     "config" : {
-        "windownloadurl_ia32" : "http://dl.dropboxusercontent.com/u/4709222/ejdb/tcejdb-1.1.23-mingw32-i686.zip",
-        "windownloadurl_x64" : "http://dl.dropboxusercontent.com/u/4709222/ejdb/tcejdb-1.1.23-mingw32-x86_64.zip"
+        "windownloadurl_ia32" : "http://dl.dropboxusercontent.com/u/4709222/ejdb/tcejdb-1.1.24-mingw32-i686.zip",
+        "windownloadurl_x64" : "http://dl.dropboxusercontent.com/u/4709222/ejdb/tcejdb-1.1.24-mingw32-x86_64.zip"
     },
     "main" : "node/ejdb.js",
     "homepage" : "http://ejdb.org",
index 426797b..c08c8b5 100755 (executable)
@@ -26,7 +26,7 @@ function _npm() {
     sed -i 's/\"version\" *\: *.*\,/"version" : \"'"$1"'\"\,/' ./package.json
     sed -r -i 's/tcejdb-[[:digit:]]+\.[[:digit:]]+\.[[:digit:]]+-/tcejdb-'"$1"'-/g' ./package.json || exit $?
     make clean
-    ##npm publish || exit $?
+    npm publish || exit $?
     exit 0;
 }
 
@@ -60,6 +60,18 @@ function _win() {
   exit 0;
 }
 
+
+function _git() {
+    echo "Publishing into GIT"
+    cd ${EJDB_HOME}
+    VERSION="$1"
+    git commit -a -m"v${VERSION}" || exit $?
+    git tag "v${VERSION}" || exit $?
+    git push --tags || exit $?
+    exit 0;
+}
+
+
 function tcejdb() {
     TCEJDB_HOME="${EJDB_HOME}/tcejdb"
     VERSION="$1"
@@ -71,7 +83,7 @@ function tcejdb() {
     fi
 
     if [[ ${CMDS} =~ ^\ +$ ]]; then
-       CMDS="dput w32 w64";
+       CMDS="dput w32 w64 npm git";
     fi
 
     cd ${TCEJDB_HOME}
@@ -133,6 +145,9 @@ function tcejdb() {
             "w64" )
                 (_win "w64" ${VERSION}) || exit $?
             ;;
+            "git" )
+                (_git ${VERSION}) || exit $?
+            ;;
             * )
                 echo "Invalid command";
                 usage