Skip to content

Instantly share code, notes, and snippets.

@mikeatlas
Forked from hnakamur/parse_iso8601.go
Created October 12, 2015 01:40
Show Gist options
  • Save mikeatlas/fe9eef438c8903e4b4bd to your computer and use it in GitHub Desktop.
Save mikeatlas/fe9eef438c8903e4b4bd to your computer and use it in GitHub Desktop.
parse ISO8601 datetime in go http://play.golang.org/p/xe2mWIHZGU
package main
import (
"fmt"
"time"
)
func main() {
t, err := time.Parse(time.RFC3339Nano, "2013-06-05T14:10:43.678Z")
if err != nil {
panic(err)
}
fmt.Println(t)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment