@kjk1/

gobook time strftime

Go

No description

fork
loading
Files
  • main.go

This Plugin Crashed!

Error: Error: must not create an existing file {"type":"CREATE_FILE","wid":"0.5413259025783606","path":"main.go","file":{"path":"main.go","content":{"asEncoding":{"base64":"Ly8gbm8gcGxheWdyb3VuZApwYWNrYWdlIG1haW4KCmltcG9ydCAoCgkiZm10IgoJInRpbWUiCgoJc3RyZnRpbWUgImdpdGh1Yi5jb20vamVoaWFoL2dvLXN0cmZ0aW1lIgopCgpmdW5jIG1haW4oKSB7CgkvLyA6c2hvdyBzdGFydAoJdCA6PSB0aW1lLkRhdGUoMjAxNywgOSwgNCwgMywgMzgsIDQ1LCAwLCB0aW1lLlVUQykKCWZtdC5QcmludGxuKHN0cmZ0aW1lLkZvcm1hdCgiJVktJW0tJWQgJUg6JU06JVMiLCB0KSkKCS8vIDpzaG93IGVuZAp9"},"asBuffer":null},"loaded":true}}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// no playground
package main

import (
	"fmt"
	"time"

	strftime "github.com/jehiah/go-strftime"
)

func main() {
	// :show start
	t := time.Date(2017, 9, 4, 3, 38, 45, 0, time.UTC)
	fmt.Println(strftime.Format("%Y-%m-%d %H:%M:%S", t))
	// :show end
}