Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add node.version

  • Loading branch information...
commit 1bf9be6b374261a7fd4ac2cf5143d36268ed178f 1 parent e10fbab
@ry ry authored
Showing with 4 additions and 3 deletions.
  1. +2 −0  src/node.cc
  2. +2 −0  src/node.h
  3. +0 −3  wscript
View
2  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<Array> arguments = Array::New(argc);
for (int i = 0; i < argc; i++) {
Local<String> arg = String::New(argv[i]);
View
2  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))
View
3  wscript
@@ -6,9 +6,6 @@ from logging import fatal
import js2c
-VERSION='0.1.2'
-APPNAME='node'
-
srcdir = '.'
blddir = 'build'
cwd = os.getcwd()
Please sign in to comment.
Something went wrong with that request. Please try again.