golang: Get last character of a string

A very quick one here. I needed to get the last character of a string in golang, but thinking like a PHP developer I was looking for an equivalent to substr($var, -1);.

golang: How to `go get` private repos

Recently, I've been working on some golang projects at DataSift that depend on some private modules. This means that when I run go get to fetch the module, GitHub asks me for my username and …

Golang: Using Memcached

If you want to use memcached in a Golang project, the most recommended library is is memcache from Brad Fitzpatrick. Brad is both the author of memcache and a Golang core team member, which means …

golang: Encode/Decode arbitrary JSON

Just a quick post in case I forget how to do this in future. I had a use case for working with reading arbitrary JSON from a file and parsing it using Golang, which meant that the recommended way of …

golang: invalid operation: someVar == "" (mismatched types *string and string)

I was trying to see if a value was empty in a golang script I was writing, when I came across an odd error message: