cloudcalvin
4/29/2015 - 9:08 AM

happy_golang_libraries.md

Happy Time Go Libraries.

Another curated list like awesome-go.
Not complete. Not authoritative. Not cupcake.
Send suggestions: @squarism :)
☆ = Github stars (in September 2014)


Adapters and Drivers

Postgres
github.com/lib/pq (886☆)

MySQL
github.com/go-sql-driver/mysql (927☆)

Sqlite
github.com/mattn/go-sqlite3 (481☆)

RethinkDB
github.com/dancannon/gorethink (217☆)

MongoDB
labix.org/v2/mgo

Memcached
github.com/bradfitz/gomemcache/memcache (325☆)

Redis
github.com/garyburd/redigo/redis (877☆)

Elastigo - A Go (golang) based Elasticsearch client library.
github.com/mattbaird/elastigo (311☆)

Databases in Go

Bolt - A low-level key/value database for Go
github.com/boltdb/bolt (791☆)

Go-cache - An in-memory key:value store/cache (similar to Memcached), suitable for single-machine apps
github.com/pmylund/go-cache (171☆)

Doozer - A consistent distributed data store for small amounts of extremely important data.
github.com/ha/doozerd (2131☆)

etd - A highly-available key value store for shared configuration and service discovery
github.com/coreos/etcd (4225☆)

Cockroach - A Scalable, Geo-Replicated, Transactional Datastore
github.com/cockroachdb/cockroach (1507☆) † (TODO: needs rocksdb installed by hand)

Date

Now - date math sugar now.EndOfWeek()
github.com/jinzhu/now (216☆)

Email

Email - email for humans
github.com/jordan-wright/email (475☆)

Image Processing

Gift - image processing with no dependencies
github.com/disintegration/gift (468☆)

Internet

Hellabot - irc bot framework
github.com/whyrusleeping/hellabot (61☆)

Logging

Logrus - structured, pluggable logging for Go.
github.com/sirupsen/logrus (549☆)

Machine Learning

Golearn - GoLearn is a 'batteries included' machine learning library for Go.
github.com/sjwhitworth/golearn (1367☆)

Shield - English text bayes classifier
github.com/eaigner/shield (44☆)

Messaging

AMQP - rabbitmq client
github.com/streadway/amqp (391☆)

Go-workers - sidekiq compatible workers
github.com/jrallison/go-workers (264☆)

Libchan - like go channels over the network
github.com/docker/libchan (1345☆)

Gozmq - Go (golang) bindings for the ZeroMQ 4
github.com/pebbe/zmq4 (127☆)

Beanstalk - Go client for beanstalkd
github.com/kr/beanstalk (51☆)

nsq - A realtime distributed messaging platform
github.com/bitly/go-nsq (210☆)

Monitoring

I want to call this section DevOps but I won't. :)

Influxdb - Metrics! Influx->Graphana (UI) Like statsd+graphite.
github.com/influxdb/influxdb/client (2983☆)

Graphite-ng - Next generation graphite server
github.com/graphite-ng/graphite-ng (250☆)

ORMs

Gorp - ORM-ish (go doesn't have objects really) library for Go
github.com/coopernurse/gorp (1116☆)

Package Management

Gpm - minimalistic package manager for Go
github.com/pote/gpm (442☆) †

Templates

Mustache - The mustache template language in Go
github.com/hoisie/mustache (616☆)

Testing

Ginkgo - BDD testing
github.com/onsi/ginkgo (460)

GoConvey - a yummy Go testing tool for gophers. Works with go test.
github.com/smartystreets/goconvey (1103☆)

Gory - Factories for your Go structs. Think factory_girl.
github.com/modocache/gory (17☆)

Testify - A sacred extension to the standard go testing package (mocks) github.com/stretchr/testify (704☆)

Looper - Like guard for go (or autotest) github.com/nathany/looper (143☆)

Text

Blackfriday - a markdown processor for Go
github.com/russross/blackfriday (911☆)

Toml - TOML parser
github.com/BurntSushi/toml (288☆)

YAML - yaml 1.2 parser
bitbucket.org/zombiezen/yaml (32 watchers)

Gokogiri - libxml nokogiri port
github.com/moovweb/gokogiri (287☆)

Utilities and Miscellaneous

Gox - cross compiling made dead easy
github.com/mitchellh/gox (588☆)

Utils - general utils from the docker repo
github.com/dotcloud/docker/blob/master/utils (15k☆**) †

Gojson - gojson attempts to generate go struct definitions from json documents
github.com/ChimeraCoder/gojson (322☆)

Cobra - Command Line Options
github.com/spf13/cobra (484☆)

Dotenv - put app settings into .env file, deployment happiness
github.com/joho/godotenv (84☆)

Gopencils - Easily consume REST APIs with Go
github.com/bndr/gopencils (246☆)

go-spew - Implements a deep pretty printer for Go data structures to aid in debugging
github.com/davecgh/go-spew/spew (323☆)

goagain - Zero-downtime restarts in Go
github.com/rcrowley/goagain (996☆)

Text User Interfaces

Termbox-go - cross Win/Linux TUI API to make terminal UIs
github.com/nsf/termbox-go (461☆)

Color - ANSI color library
github.com/fatih/color (138☆)

Web

Go.auth - Authentication API for Go web applications.
github.com/bradrydzewski/go.auth (204☆)

Binding - Binds form and JSON data from net/http Request to struct.
github.com/mholt/binding (216☆)

Nosurf - A CSRF protection middleware for Go.
github.com/justinas/nosurf (273☆)

Martini - classy web framework (sinatra inspired)
github.com/go-martini/martini (5347☆)

Render - easy rendering serialized JSON, XML, and HTML template responses
github.com/martini-contrib/render (109☆)

Negroni - idiomatic http middleware
github.com/codegangsta/negroni (1363☆)

Gin - Gin is like Martini but really fast
github.com/gin-gonic/gin (1409☆)

Goji - Goji is a minimalistic web framework for Golang that's high in antioxidants
github.com/zenazn/goji (1564☆)

Editors and tools

you would probably not install these like libraries

GoSublime - Sublime Text 2 plugin. Does code completion and fixes imports (among other things)
github.com/DisposaBoy/GoSublime (1334☆) †

Vim-go - vim plugin
github.com/fatih/vim-go (1133☆) †

** docker has 13,000 stars but that's the whole project
† uninstallable via go get

Quick install script

for library in `curl -s \
https://gist.github.com/squarism/914b26e316a2cb204188 \
| grep -v † | grep -E "^<code>.*</code>" | sed -e 's/<[^>]*>//g' | awk '{print $1}'`
do go get -u $library
  echo '-->' $library done.
done

# some above are not golang repos or have special installation paths
brew install gpm
go get github.com/dotcloud/docker/utils

Many of these require dependencies, like yum, rpm, apt-get or brew install fun times.

TODO: list out all the depenencies for like one platform (mac) as a hint.

brew install zmq hg gflagsl

If you don't have go this do this in homebrew:

brew install go --cross-compile-common