mirror of
https://github.com/Threnklyn/jira.git
synced 2026-06-07 13:33:32 +02:00
add "comment" template filter to comment out multiline statements
This commit is contained in:
@@ -132,6 +132,9 @@ func runTemplate(templateContent string, data interface{}, out io.Writer) error
|
|||||||
}
|
}
|
||||||
return strings.Replace(content, "\n", string(indent), -1)
|
return strings.Replace(content, "\n", string(indent), -1)
|
||||||
},
|
},
|
||||||
|
"comment": func(content string) string {
|
||||||
|
return strings.Replace(content, "\n", "\n# ", -1)
|
||||||
|
},
|
||||||
"color": func(color string) string {
|
"color": func(color string) string {
|
||||||
return ansi.ColorCode(color)
|
return ansi.ColorCode(color)
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user