package admin import ( "github.com/GeertJohan/go.rice/embedded" "time" ) func init() { // define files file2 := &embedded.EmbeddedFile{ Filename: `index.html`, FileModTime: time.Unix(1489315188, 0), Content: string("\n\n\n \n \n {{.Config.Site.Title}} Admin Login\n \n \n \n\n\n
\n
\n \n
\n \n
\n
\n \n
\n
\n \n \n
\n \n
\n\n"), } file3 := &embedded.EmbeddedFile{ Filename: `panel.html`, FileModTime: time.Unix(1489566364, 0), Content: string("\n\n\n \n \n {{.Config.Site.Title}} Admin Panel\n \n \n \n\n\n
\n Welcome {{.Admin.Id}}
\n
\n \n \n \n
\n

\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n Action\n \n New Board\n \n
\n Short Name\n \n \n
\n Long Name\n \n \n
\n \n \n
\n
\n
\n

\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n Action\n \n New Administrator\n \n
\n ID\n \n \n
\n Password\n \n \n
\n \n \n
\n
\n
\n

\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n Action\n \n Delete Administrator\n \n
\n ID\n \n \n
\n \n \n
\n
\n
\n

\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n
\n Action\n \n Cleanup Database\n \n
\n \n \n
\n
\n
\n

\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n Action\n \n Set Board Rules\n \n
\n Board Name (Short)\n \n \n
\n Rules\n \n \n \n
\n \n \n
\n
\n
\n

\n\n"), } file4 := &embedded.EmbeddedFile{ Filename: `status.html`, FileModTime: time.Unix(1489525499, 0), Content: string("\n\n\n \n \n {{.Config.Site.Title}} Status\n \n \n \n\n\n
\n

Runtime Statistics

\n
\n
\n
\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n Start Time\n \n {{.Uptime.human}}\n
\n Uptime (Precise)\n \n {{ .Uptime.hours | printf \"%.4f\"}} hours
\n {{ .Uptime.seconds | printf \"%.4f\"}} seconds\n
\n Num. CPU\n \n {{.GC.numcpu}}\n
\n Num. GoRoutines\n \n {{.GC.numgor}}\n
\n Go Version
\n Arch/OS/Compiler\n
\n {{.GC.version}}
\n {{.GC.arch}} / {{.GC.os}} / {{.GC.compiler}}\n
\n Current Allocs\n \n {{.GC.memory.alloc}}\n
\n Cumulative Allocs\n \n {{.GC.memory.calloc}}\n
\n Used Sys Memory\n \n {{.GC.memory.sysmem}}\n
\n Pointer Lookups\n \n {{.GC.memory.lookups}}\n
\n MAllocs\n \n {{.GC.memory.mallocs}}\n
\n MFrees\n \n {{.GC.memory.frees}}\n
\n Live Objects\n \n {{.GC.memory.liveobj}}\n
\n Heap Allocated\n \n {{.GC.memory.heapalloc}}\n
\n Heap Released\n \n {{.GC.memory.heaprelease}}\n
\n GC Metadata\n \n {{.GC.memory.gcmeta}}\n
\n GC Pause\n \n {{.GC.memory.pause}}\n
\n GC Invokations\n \n {{.GC.memory.gctimes}}\n
\n GC Forced\n \n {{.GC.memory.fgctimes}}\n
\n GC CPU Usage\n \n {{.GC.memory.cpufrac}}\n
\n
\n
\n

\n\n"), } // define dirs dir1 := &embedded.EmbeddedDir{ Filename: ``, DirModTime: time.Unix(1489566364, 0), ChildFiles: []*embedded.EmbeddedFile{ file2, // index.html file3, // panel.html file4, // status.html }, } // link ChildDirs dir1.ChildDirs = []*embedded.EmbeddedDir{} // register embeddedBox embedded.RegisterEmbeddedBox(`res/`, &embedded.EmbeddedBox{ Name: `res/`, Time: time.Unix(1489566364, 0), Dirs: map[string]*embedded.EmbeddedDir{ "": dir1, }, Files: map[string]*embedded.EmbeddedFile{ "index.html": file2, "panel.html": file3, "status.html": file4, }, }) }