Skip to content

Instantly share code, notes, and snippets.

{
"name": "cluster",
"children": [
{"name": "0", "size": 6.6240652278 },
{"name": "1", "size": 2.48490664979 },
{"name": "2", "size": 2.63905732962 },
{"name": "3", "size": 2.19722457734 },
{"name": "4", "size": 2.3978952728 },
{"name": "5", "size": 2.3978952728 },
@hyzhangsf
hyzhangsf / statsd.md
Created March 19, 2016 00:54 — forked from trusche/statsd.md
Installing graphite and statsd on OS X Yosemite

Prerequisites

  • Homebrew
  • Python 2.7
  • Git

Graphite

Install Cairo

There's an issue with cairo 14.x that results in the axis fonts on the graphs being HUUUUUGE. Downgrading to 12.6 helps:

@hyzhangsf
hyzhangsf / homebrew_notes.md
Last active April 13, 2016 22:28
homebrew notes
  1. cleanup cache

    brew cleanup

  2. check health

    brew doctor

  3. list outdated

brew outdated

---
title: "Hack Day"
author: "Hanyu Zhang"
date: "March 18, 2016"
output: html_document
---
This is an R Markdown document. Markdown is a simple formatting syntax for authoring HTML, PDF, and MS Word documents. For more details on using R Markdown see <http://rmarkdown.rstudio.com>.
When you click the **Knit** button a document will be generated that includes both content as well as the output of any embedded R code chunks within the document. You can embed an R code chunk like this:
@hyzhangsf
hyzhangsf / gist:5786ea6e6a053557e15b
Created March 15, 2016 22:54 — forked from kingbin/gist:9435292
Manually Start/Stop PostgresSQL on Mac
# Stop PostgreSQL from auto starting
sudo launchctl unload -w /Library/LaunchDaemons/com.edb.launchd.postgresql-9.3.plist
# Enable PostgreSQL to auto start
sudo launchctl load -w /Library/LaunchDaemons/com.edb.launchd.postgresql-9.3.plist
# Start postgres
$ sudo su postgres
Password:
bash-3.2$ pg_ctl -D /Library/PostgreSQL/9.3/data/ start
http://plnkr.co/edit/4nPt5Mj6GEeq1tjjTv5Z?p=preview
<!DOCTYPE html>
<html>
<head>
<!-- Latest compiled and minified CSS -->
<script src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.12.0.min.js"></script>
<script src="https://cdn.datatables.net/1.10.11/js/jquery.dataTables.min.js"></script>
<script src="https://cdn.datatables.net/1.10.11/js/dataTables.bootstrap.min.js"></script>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" integrity="sha384-1q8mTJOASx8j1Au+a5WDVnPi2lkFfwwEAa8hDDdjZlpLegxhjVME1fgjWPGmkzs7" crossorigin="anonymous">
<!-- Optional theme -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap-theme.min.css" integrity="sha384-fLW2N01lMqjakBkx3l/M9EahuwpSfeNvV63J5ezn3uZzapT0u7EYsXMjQV+0En5r" crossorigin="anonymous">
@hyzhangsf
hyzhangsf / gist:4122b61df1c7c5889cbf
Created January 7, 2016 20:47
download all files on an apache directory listing
# http://stackoverflow.com/questions/5317219/apache-directory-listing-download-all
wget -m -np http://eamos.pf.jcu.cz/amos/kat_inf/externi/
@hyzhangsf
hyzhangsf / patch-wget-list
Created December 23, 2015 20:07
LFS 7.8 Patches
http://www.linuxfromscratch.org/patches/lfs/7.8/bash-4.3.30-upstream_fixes-2.patch
http://www.linuxfromscratch.org/patches/lfs/7.8/bc-1.06.95-memory_leak-1.patch
http://www.linuxfromscratch.org/patches/lfs/7.8/bzip2-1.0.6-install_docs-1.patch
http://www.linuxfromscratch.org/patches/lfs/7.8/coreutils-8.24-i18n-1.patch
http://www.linuxfromscratch.org/patches/lfs/7.8/glibc-2.22-fhs-1.patch
http://www.linuxfromscratch.org/patches/lfs/7.8/glibc-2.22-upstream_i386_fix-1.patch
http://www.linuxfromscratch.org/patches/lfs/7.8/kbd-2.0.3-backspace-1.patch
http://www.linuxfromscratch.org/patches/lfs/7.8/mpfr-3.1.3-upstream_fixes-1.patch
http://www.linuxfromscratch.org/patches/lfs/7.8/readline-6.3-upstream_fixes-3.patch
http://www.linuxfromscratch.org/patches/lfs/7.8/sysvinit-2.88dsf-consolidated-1.patch
@hyzhangsf
hyzhangsf / tmux.cheat
Created December 22, 2015 22:02 — forked from afair/tmux.cheat
Tmux Quick Reference & Cheat sheet - 2 column format for less scrolling!
========================================== ==========================================
TMUX COMMAND WINDOW (TAB)
========================================== ==========================================
List tmux ls List ^b w
New -s <session> Create ^b c
Attach att -t <session> Rename ^b , <name>
Rename rename-session -t <old> <new> Last ^b l (lower-L)
Kill kill-session -t <session> Close ^b &