Skip to content

Instantly share code, notes, and snippets.

var req = require('request'),
cheerio = require('cheerio'),
async = require('async'),
urls = ["http://google.com/", "http://test.de/", "http://bild.de/"];
function crawlUrl(url, callback) {
"use strict";
var array = [];
@cxreg
cxreg / gist:4577093
Created January 20, 2013 07:08
node async
var async = require('async');
function one(cb) {
console.log("one");
cb();
}
function two(cb) {
function three(callback){
var a = [];
var httprequest = require('request');
var page = 1;
var maxPage = 50;
function performAfterLoadAttempt(error, response, body) {
"use strict";
//Log the Body
console.log(body);
@nono
nono / redis2txt.rb
Created November 28, 2011 23:29
Export data from redis to a plain text files
#!/usr/bin/env ruby
require "redis"
redis = Redis.new
redis.keys("*").each do |key|
val = case redis.type(key)
when "string"
redis.get key
when "list"