Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/perl
use 5.008;
use strict;
use Memoize;
# usage:
# git-large-files 500k
# git-large-files 0.5m
# git-large-files 5b
#!/bin/bash
# this will install everything as root, so take that into account before you run it
set -eu
# need cmake, python development headers, ZLib and OpenSSL
sudo apt-get install -y cmake python2.7-dev zlib1g-dev libssl-dev
root=`pwd`
@ifduyue
ifduyue / 0_reuse_code.js
Created May 24, 2014 11:30
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console

PyCon 2012 Digest

from DevOps team {rduplain,mattd,teebes}, to mobile developers at WillowTree Apps

Pronunciation

@ifduyue
ifduyue / .bashrc
Last active December 25, 2015 03:49 — forked from atduskgreg/.bashrc
PS1="\[\033[01;35m\]\u\[\033[00m\]@\[\033[01;38m\]\h:\[\033[00m\]\[\e[1;34m\]\w\[\e[0m\] \$(parse_git_branch)\$(parse_git_dirty)\$ "
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
}
parse_git_dirty() {
if [[ -d .git ]]; then
[[ $(git status) =~ "nothing to commit, working directory clean" ]] || echo "*"
fi

Markdown and reStructuredText

GitHub supports several lightweight markup languages for documentation; the most popular ones (generally, not just at GitHub) are Markdown and reStructuredText. Markdown is sometimes considered easier to use, and is often preferred when the purpose is simply to generate HTML. On the other hand, reStructuredText is more extensible and powerful, with native support (not just embedded HTML) for tables, as well as things like automatic generation of tables of contents.