start new:
tmux
start new with session name:
tmux new -s myname
(import '(java.net DatagramSocket DatagramPacket)) | |
(def socket (DatagramSocket. 5200)) | |
(def running (atom true)) | |
(def buffer (make-array Byte/TYPE 1024)) | |
(defn parse [packet] | |
(println (String. (.getData packet) 0 (.getLength packet)))) | |
(defn start-receiver [] |
# Orignal version taken from http://www.djangosnippets.org/snippets/186/ | |
# Original author: udfalkso | |
# Modified by: Shwagroo Team and Gun.io | |
import sys | |
import os | |
import re | |
import hotshot, hotshot.stats | |
import tempfile | |
import StringIO |
mitsuhiko at atherton in ~ | |
$ curl -i www.google.com | |
HTTP/1.1 302 Found | |
Location: http://www.google.co.uk/ | |
Cache-Control: private | |
Content-Type: text/html; charset=UTF-8 | |
Set-Cookie: expires=; expires=Mon, 01-Jan-1990 00:00:00 GMT; path=/; domain=www.google.com | |
Set-Cookie: path=; expires=Mon, 01-Jan-1990 00:00:00 GMT; path=/; domain=www.google.com | |
Set-Cookie: domain=; expires=Mon, 01-Jan-1990 00:00:00 GMT; path=/; domain=www.google.com | |
Set-Cookie: expires=; expires=Mon, 01-Jan-1990 00:00:00 GMT; path=/; domain=www.google.com |
L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns
Compress 1K bytes with Zippy ............. 3,000 ns = 3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns = 20 µs
SSD random read ........................ 150,000 ns = 150 µs
Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs
# How to generate a secret key with Python | |
# via http://flask.pocoo.org/docs/quickstart/ | |
import os | |
os.urandom(24) |
ಠ_ಠ | |
( ͡° ͜ʖ ͡°) | |
¯\_(ツ)_/¯ | |
(╯°□°)╯︵ ┻━┻ | |
http://www.fileformat.info/convert/text/upside-down.htm | |
WRTTN http://wrttn.me/30dbfd/ | |
Unicode Emoticons |