Node
cbcgkx
这个作者很懒,什么都没留下…
展开
-
windows 下安装 npm
第一步: 下载node.js的windows版当前最新版本是http://nodejs.org/dist/v0.6.0/node.exe第二步:设置环境变量把node.exe所在目录加入到PATH环境变量中。配置成功后可以在CMD中通过node --version 看到node.js对应的版本号C:\Users\fn>node --versionv0.5.10...原创 2011-11-11 10:56:00 · 116 阅读 · 0 评论 -
node util模块
util.log(str);添加时间戳 并输出字符串util.debug(str); 添加debug前缀 调试输出util.inspect(obj,boolean,depth);列出关于object的属性util.inherits(constructor, superConstructor...原创 2011-11-11 12:20:25 · 86 阅读 · 0 评论 -
cygwin 安装 npm
git clone --recursive git://github.com/isaacs/npm.gitcd npmnode cli.js install npm -gf 测试一下 node install -d原创 2011-11-13 00:37:10 · 133 阅读 · 0 评论 -
node express configure
configure用来配置开发环境 var express = require("express"); var app = express.createServer(); app.configure(function(){ //在任何情况下都会执行该配置}); app.configure("development",function(){ //默认的环境...原创 2011-11-24 09:56:26 · 234 阅读 · 0 评论 -
node path
path.exists("/etc/passwd",function(res){ console.log(res);}); path.extname("/home/name/index.html"); // .html path.basename("dir"[,ext]);//ext代表后缀名 ex:path.basename("/home/name/index....原创 2011-11-24 17:00:49 · 98 阅读 · 0 评论