Skip to content

Instantly share code, notes, and snippets.

@dickwu
dickwu / shell.sh
Created November 23, 2017 16:27 — forked from webfrogs/shell.sh
Output swift function information whose compile time is large than 100ms
xcodebuild -workspace XXX.xcworkspace -scheme XXX clean build OTHER_SWIFT_FLAGS="-Xfrontend -debug-time-function-bodies" | grep '^\d\{3,\}[.]\{1\}'
@dickwu
dickwu / weibopicbed.js
Created November 23, 2017 14:56 — forked from easychen/weibopicbed.js
微博图床上传函数
// from https://github.com/suxiaogang/WeiboPicBed
// under its license
function uploadToWeibo( url , callback )
{
var xhr = new XMLHttpRequest();
xhr.onload = function() {
var reader = new FileReader();
reader.onloadend = function( e )
{