Documentation
      ¶
    
    
  
    
  
    Index ¶
- func ActionContent2Commits(act Actioner) *models.PushCommits
 - func ActionIcon(opType int) string
 - func DiffLineTypeToStr(diffType int) string
 - func DiffTypeToStr(diffType int) string
 - func List(l *list.List) chan interface{}
 - func Mailer() *template.Template
 - func NewFuncMap() []template.FuncMap
 - func RenderCommitMessage(full bool, msg, urlPrefix string, metas map[string]string) template.HTML
 - func Renderer() macaron.Handler
 - func ReplaceLeft(s, old, new string) string
 - func Safe(raw string) template.HTML
 - func SafeJS(raw string) template.JS
 - func Sha1(str string) string
 - func Str2html(raw string) template.HTML
 - func ToUTF8(content string) string
 - func ToUTF8WithErr(content []byte) (string, error)
 - type Actioner
 
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ActionContent2Commits ¶
func ActionContent2Commits(act Actioner) *models.PushCommits
ActionContent2Commits converts action content to push commits
func ActionIcon ¶
ActionIcon accepts a int that represents action operation type and returns a icon class name.
func DiffLineTypeToStr ¶
DiffLineTypeToStr returns diff line type name
func NewFuncMap ¶
NewFuncMap returns functions for injecting to templates
func RenderCommitMessage ¶
RenderCommitMessage renders commit message with XSS-safe and special links.
func Renderer ¶
func Renderer() macaron.Handler
Renderer implements the macaron handler for serving the templates.
func ReplaceLeft ¶
ReplaceLeft replaces all prefixes 'old' in 's' with 'new'.
func ToUTF8WithErr ¶
ToUTF8WithErr converts content to UTF8 encoding
Types ¶
 Click to show internal directories. 
   Click to hide internal directories.