From 1bf9be6b374261a7fd4ac2cf5143d36268ed178f Mon Sep 17 00:00:00 2001 From: Ryan Date: Mon, 3 Aug 2009 17:51:35 +0200 Subject: [PATCH] Add node.version --- src/node.cc | 2 ++ src/node.h | 2 ++ wscript | 3 --- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/node.cc b/src/node.cc index f82aff3e36..3989d47836 100644 --- a/src/node.cc +++ b/src/node.cc @@ -230,6 +230,8 @@ Load (int argc, char *argv[]) global_obj->Set(String::NewSymbol("node"), node_obj); + node_obj->Set(String::NewSymbol("version"), String::New(NODE_VERSION)); + Local arguments = Array::New(argc); for (int i = 0; i < argc; i++) { Local arg = String::New(argv[i]); diff --git a/src/node.h b/src/node.h index 1724d9bc33..fd18fa3c37 100644 --- a/src/node.h +++ b/src/node.h @@ -10,6 +10,8 @@ namespace node { +#define NODE_VERSION "0.1.2" + #define NODE_DEFINE_CONSTANT(target, constant) \ (target)->Set(v8::String::NewSymbol(#constant), \ v8::Integer::New(constant)) diff --git a/wscript b/wscript index 9c19555179..4c4c158c69 100644 --- a/wscript +++ b/wscript @@ -6,9 +6,6 @@ from logging import fatal import js2c -VERSION='0.1.2' -APPNAME='node' - srcdir = '.' blddir = 'build' cwd = os.getcwd()