{"modulePath":"github.com/devfans/gogs","version":"v0.11.53","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package template\n\n## Functions\n\n```go\nfunc ActionContent2Commits(act Actioner) *models.PushCommits\n```\n\n```go\nfunc ActionIcon(opType int) string\n```\nActionIcon accepts a int that represents action operation type and returns a icon class name.\n\n```go\nfunc DiffLineTypeToStr(diffType int) string\n```\n\n```go\nfunc DiffTypeToStr(diffType int) string\n```\n\n```go\nfunc EscapePound(str string) string\n```\n\n```go\nfunc List(l *list.List) chan interface{}\n```\n\n```go\nfunc NewFuncMap() []template.FuncMap\n```\nTODO: only initialize map once and save to a local variable to reduce copies.\n\n```go\nfunc NewLine2br(raw string) string\n```\nNewLine2br simply replaces \"\\\\n\" to \"\\\u003cbr\u003e\".\n\n```go\nfunc RenderCommitMessage(full bool, msg, urlPrefix string, metas map[string]string) template.HTML\n```\nRenderCommitMessage renders commit message with XSS-safe and special links.\n\n```go\nfunc ReplaceLeft(s, old, new string) string\n```\nReplaces all prefixes 'old' in 's' with 'new'.\n\n```go\nfunc Safe(raw string) template.HTML\n```\n\n```go\nfunc Sha1(str string) string\n```\n\n```go\nfunc Str2html(raw string) template.HTML\n```\n\n```go\nfunc ToUTF8(content string) string\n```\n\n```go\nfunc ToUTF8WithErr(content []byte) (error, string)\n```\n\n## Types\n\n```go\ntype Actioner interface {\n\tGetOpType() int\n\tGetActUserName() string\n\tGetRepoUserName() string\n\tGetRepoName() string\n\tGetRepoPath() string\n\tGetRepoLink() string\n\tGetBranch() string\n\tGetContent() string\n\tGetCreate() time.Time\n\tGetIssueInfos() []string\n}\n```\n\n","path":"github.com/devfans/gogs/pkg/template","name":"template","synopsis":"","isRedistributable":true}
