Skip to content

Instantly share code, notes, and snippets.

@cou929
cou929 / README.md
Created December 16, 2012 12:08 — forked from Jxck/README.md
libuv サンプル. tcp server & client. クライアントがファイル名を送り, サーバでは足元からファイルを読んでクライアントに返す.

how to compile

$ gcc -g -Wall -I /path/to/libuv/include /path/to/libuv/uv.a -framework CoreServices server.c -o server
$ gcc -g -Wall -I /path/to/libuv/include /path/to/libuv/uv.a -framework CoreServices client.c -o client
#!/bin/sh
# Just copy and paste the lines below (all at once, it won't work line by line!)
# MAKE SURE YOU ARE HAPPY WITH WHAT IT DOES FIRST! THERE IS NO WARRANTY!
function abort {
echo "$1"
exit 1
}
set -e
@cou929
cou929 / mt_to_markdown.rb
Created August 6, 2017 04:16 — forked from code-later/mt_to_markdown.rb
Convert a MovableType export to single Markdown posts to use with Octopress
#!/usr/bin/env ruby
require 'date'
require 'mustache'
require 'stringex'
require 'cgi'
require 'fileutils'
export = File.open(ARGV[0])
target_dir = ARGV[1]