This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
0 0 * * * rm -Rf /home/me/tmp/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var sys = require("sys"), | |
http = require("http"), | |
fs = require('fs'), | |
path = require('path'); | |
http.createServer(function(request, response) { | |
var headers = { "Content-Type": "text/html" }; | |
var filename = path.join(process.cwd(), 'work/terminix/knox/index.html'); | |
path.exists(filename, function(exists) { | |
if(!exists) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var sys = require('sys') | |
,events = require('events') | |
function Eventer() { | |
events.EventEmitter.call(this); | |
} | |
sys.inherits(Eventer, events.EventEmitter); | |
var eventer = new Eventer(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
it('can haz cloned node', function() { | |
var gchild_string = '<grandchild from="julie numar">with love</grandchild>'; | |
var doc1_string = [ | |
'<?xml version="1.0" encoding="UTF-8"?>', | |
'<root><child to="wongfoo">'+gchild_string+'</child><sibling>with content!</sibling></root>', | |
'' | |
].join("\n"); | |
var doc2_string = [ | |
'<?xml version="1.0" encoding="UTF-8"?>', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 37f3ea740829e95e733951aab8def5d525a0bc29 Mon Sep 17 00:00:00 2001 | |
From: Nick Campbell <[email protected]> | |
Date: Thu, 16 Dec 2010 10:54:04 -0500 | |
Subject: [PATCH] Match lowercased protocols so that protocols can be specified in any way. | |
Signed-off-by: Nick Campbell <[email protected]> | |
--- | |
lib/url.js | 18 +++++++++++------- | |
test/simple/test-url.js | 6 ++++++ | |
2 files changed, 17 insertions(+), 7 deletions(-) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var htmlparser = require('htmlparser'), | |
sys = require('sys'), | |
http = require('http'), | |
compress_lib = require('compress'), | |
gunzip = new compress_lib.GunzipStream(); | |
var domain = 'www.example.com'; //TODO: CHANGE ME | |
var rawHtml = "Xyz <script language= javascript>var foo = '<<bar>>';< / script><!--<!-- Waah! -- -->"; | |
var handler = new htmlparser.DefaultHandler(function (error, dom) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var nodeunit = require('nodeunit'); | |
function testCase(suite){ | |
suite.setUp = function(test){ | |
// your stuff | |
}; | |
suite.tearDown = function(test){ | |
// your stuff | |
}; | |
return testCase.super_.call(this, suite); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App.prototype.save = function() { | |
var that = this, | |
stylesheets = [], | |
scripts = [], | |
fw,i,len, | |
stylesheet, script, html, savr; | |
var Saver = function(app, file) { | |
var that = this; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App.prototype.save = function() { | |
var that = this, | |
stylesheets = [], | |
scripts = [], | |
fw,i,len, | |
stylesheet, script, html, savr; | |
var Saver = function(app, file) { | |
var that = this; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var data = [1,2,3,4,5,6,7,8,9,10], | |
len = data.length, | |
count = 0; | |
function f() { | |
//do your dependent stuff here | |
} | |
data.forEach(function(i) { | |
db.save(key, {val: i}, function(err, res) { |
OlderNewer