server.js代码: var http=require('http'); var fs=require('fs'); var server=http.createServer(function(req,resp){ getTitles(resp); }); server.listen(3000,function(){ console.log('Server is listenning on port 3000.'); }); function getTitles(resp){ fs.read
原文链接:http://blog.csdn.net/zk437092645/article/details/9231787 Node.js读取文件内容包括同步和异步两种方式. 1.同步读取,调用的是readFileSync var rf=require("fs"); var data=rf.readFileSync("test","utf-8"); console.log(data); console.log("READ FILE SY
1. Sed的help 鸟哥说的 学东西 先看 help 先看man 再google 不好FQ再百度.. Usage: sed [OPTION]... {script-only-if-no-other-script} [input-file]... -n, --quiet, --silent suppress automatic printing of pattern space -e script, --expression=script add the script to the comma