Install gist-vim to quickly share code snippets.
:Gist posts the current buffer, or the current selection
It can open your browser and/or copy the url to the clipboard, default to public or private gists, detect the filetype of the code snippet, and also supports GitHub Enterprise.
See my commit to my .vimrc here: JustinCampbell/.dotfiles@013b082
Thanks to John Ewart