Skip to content

Instantly share code, notes, and snippets.

Thomas Bratt thomasbratt

  • Cambridge, UK
Block or report user

Report or block thomasbratt

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
monners / keymap.cson
Last active Sep 28, 2017
Atom keymap.cson
View keymap.cson
# Your keymap
# Atom keymaps work similarly to style sheets. Just as style sheets use
# selectors to apply styles to elements, Atom keymaps use selectors to associate
# keystrokes with events in specific contexts.
# You can create a new keybinding in this file by typing "key" and then hitting
# tab.
# Here's an example taken from Atom's built-in keymap:
stephanetimmermans / ubuntu-idea-launcher
Last active Jun 19, 2016
Add IntelliJ IDEA Launcher in Ubuntu 14.04
View ubuntu-idea-launcher
#In IDEA, go to Tools > Create Desktop Entry to create a launcher in /usr/share/applications.
cp /usr/share/applications/jetbrains-idea.desktop ~/.local/share/applications/
staltz /
Last active Feb 21, 2020
The introduction to Reactive Programming you've been missing
cridenour / gist:74e7635275331d5afa6b
Last active Feb 5, 2020
Setting up Vim as your Go IDE
View gist:74e7635275331d5afa6b

Setting up Vim as your Go IDE

The final IDE


I've been wanting to do a serious project in Go. One thing holding me back has been a my working environment. As a huge PyCharm user, I was hoping the Go IDE plugin for IntelliJ IDEA would fit my needs. However, it never felt quite right. After a previous experiment a few years ago using Vim, I knew how powerful it could be if I put in the time to make it so. Luckily there are plugins for almost anything you need to do with Go or what you would expect form and IDE. While this is no where near comprehensive, it will get you writing code, building and testing with the power you would expect from Vim.

Getting Started

I'm assuming you're coming with a clean slate. For me this was OSX so I used MacVim. There is nothing in my config files that assumes this is the case.

fatih / ring.go
Created Dec 24, 2013
container/ring example golang
View ring.go
package main
import (
func main() {
coffee := []string{"kenya", "guatemala", "ethiopia"}
temoto /
Last active Feb 6, 2020
Part of py-helpers. Gzip compression shortcuts. Encoding. Database helpers. Retry decorator.
def namedlist(typename, field_names):
"""Returns a new subclass of list with named fields.
>>> Point = namedlist('Point', ('x', 'y'))
>>> Point.__doc__ # docstring for the new class
'Point(x, y)'
>>> p = Point(11, y=22) # instantiate with positional args or keywords
>>> p[0] + p[1] # indexable like a plain list
>>> x, y = p # unpack like a regular list
jonnyreeves / index.html
Created Apr 23, 2012
JavaScript Class Structure using requireJS. The following code shows you how to create a Class definition in one JavaScript file and then import it for use in another; coming from an ActionScript 3 background this (and some of JavaScript specific traits)
View index.html
<!DOCTYPE html>
<script data-main="usage" src=""></script>
<p>Check your JavaScript console for output!</p>
robsimmons / gh-like.css
Created Aug 25, 2011 — forked from somebox/gh-like.css
GitHub-esque syntax highlight CSS
View gh-like.css
Some simple Github-like styles, with syntax highlighting CSS via Pygments.
font-family: helvetica, arial, freesans, clean, sans-serif;
color: #333;
background-color: #fff;
border: none;
line-height: 1.5;
margin: 2em 3em;
mcavage / gist:1056404
Created Jun 30, 2011
Serving static content with restify
View gist:1056404
// Docs/etc.
server.get(null, '/', function(request, response, next) {
response.send(302, null, {
Location: config.siteName + '/docs'
return next();
}, log.w3c);
server.get(null, '/docs', function(req, res, next) {
You can’t perform that action at this time.