create different ssh key according the article Mac Set-Up Git
$ ssh-keygen -t rsa -C "your_email@youremail.com"
""" | |
This is a simple example of WebSocket + Tornado + Redis Pub/Sub usage. | |
Do not forget to replace YOURSERVER by the correct value. | |
Keep in mind that you need the *very latest* version of your web browser. | |
You also need to add Jacob Kristhammar's websocket implementation to Tornado: | |
Grab it here: | |
http://gist.github.com/526746 | |
Or clone my fork of Tornado with websocket included: | |
http://github.com/pelletier/tornado | |
Oh and the Pub/Sub protocol is only available in Redis 2.0.0: |
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
"""Simple async crawler/callback queue based on gevent.""" | |
import traceback | |
import logging | |
import httplib2 | |
import gevent |
#!/usr/bin/env python | |
""" | |
Simple Indexer | |
================================= | |
Author: Jon Hurlock, October 2011 | |
This script basically crawls a domain (not just a page) and | |
then extracts all links <a href=""></a>, and finds all links | |
on that domain it also is able extract different file types |
#encoding:utf-8 | |
import logging | |
import time | |
import urllib | |
import mimetools | |
from tornado import httpclient | |
from tornado.httputil import HTTPHeaders | |
from tornado import escape | |
from tornado.auth import OAuthMixin,OAuth2Mixin |
create different ssh key according the article Mac Set-Up Git
$ ssh-keygen -t rsa -C "your_email@youremail.com"
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>Tornado WebSocket Sample</title> | |
</head> | |
<body> | |
<input type="text" id="username" value="myname" /> | |
<button id="connect">connect</button> | |
<div id="result"></div> |
i386 : iPhone Simulator | |
x86_64 : iPhone Simulator | |
arm64 : iPhone Simulator | |
iPhone1,1 : iPhone | |
iPhone1,2 : iPhone 3G | |
iPhone2,1 : iPhone 3GS | |
iPhone3,1 : iPhone 4 | |
iPhone3,2 : iPhone 4 GSM Rev A | |
iPhone3,3 : iPhone 4 CDMA | |
iPhone4,1 : iPhone 4S |
var http = require('http'); | |
var qs = require('querystring'); | |
function parse_response(res, callback) { | |
var list = []; | |
res.on('data', function(chunk) { | |
list.push(chunk); | |
}); | |
res.on('end', function() { | |
callback(Buffer.concat(list).toString()); |
import gevent | |
from gevent import monkey, queue | |
monkey.patch_all() | |
import urllib2 | |
from time import sleep | |
import traceback | |
import logging |