Alternatives: Excel style formatter: https://github.com/metakeule/fmtdate bday, err := fmtdate.NewTimeDate("YYYY-MM-DD", "2000-12-04")
C-library style formatter: https://github.com/lestrrat-go/strftime https://github.com/fastly/go-utils/strftime -- deprecated https://github.com/jehiah/go-strftime https://github.com/tebeka/strftime str, err := strftime.Format("%Y-%m-%d %H:%M:%S", t) str, err := strftime.Format("%Y/%m/%d", time.Now()) C-library style formatter with different interface, includes parsing using C-library format specifiers: https://github.com/bmuller/arrow // formatting fmt.Println("Current date: ", arrow.Now().CFormat("%Y-%m-%d %H:%M")) // parsing parsed, _ := arrow.CParse("%Y-%m-%d", "2015-06-03") Parsing: Useful for parsing date strings when you don't necessarily know the dateformat ahead of time, or the format can vary: https://github.com/araddon/dateparse Howard -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/fc4cb84f-5cde-46af-8834-2681e07f1828n%40googlegroups.com.