Skip to content

Instantly share code, notes, and snippets.

View yaotian's full-sized avatar

yaotian

View GitHub Profile
Team behind Go:
- Ken Thompson
- Co-Creator of Unix
- Co-Creator of UTF-8
- Creator of 'B', the direct predecessor to the 'C' programming language
- Rob Pike
- Member of Unix Team at Bell Labs
- Creator of Plan 9
- Co-Creator of UTF-8
package main
import (
"crypto/tls"
"net"
"net/http"
"time"
"fmt"
"errors"
)
@yaotian
yaotian / gist:4214543
Created December 5, 2012 10:24 — forked from fxsjy/gist:3550053
Bakup Weibo to Disk
package main
import (
"net/http"
"net/url"
"log"
"io/ioutil"
"regexp"
"fmt"
//"net/http/httputil"
打开/前往
⌘T 前往文件
⌘⌃P 前往项目
⌘R 前往 method
⌘⇧P 命令提示
⌃G 前往行
⌘KB 开关侧栏
⌃ ` python 控制台
⌘⇧N 新建窗口
@yaotian
yaotian / __init__.py
Created September 3, 2012 23:15 — forked from ipconfiger/__init__.py
OAuth包,实现了sina,QQ,网易,搜狐的OAuth认证
# -*- Encoding: utf-8 -*-
import base64
import binascii
import cgi
import hashlib
import hmac
import logging
import time
import urllib
import urlparse
@yaotian
yaotian / markdown.css
Created August 28, 2012 16:05 — forked from zhimiaoli/markdown.css
github的markdown的样式
.markdown-body {
font-size: 14px;
line-height: 1.6;
}
.markdown-body > *:first-child {
margin-top: 0 !important;
}
.markdown-body > *:last-child {
margin-bottom: 0 !important;
}
@yaotian
yaotian / Server.cs
Created April 14, 2012 02:02 — forked from bschwind/Server.cs
Implements a simple TCP server with one thread per client
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Net;
using System.Net.Sockets;
using System.Threading;
using System.Collections.Concurrent;
namespace GraphicsToolkit.Networking