commentutil

package
v0.14.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 27, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const BodyPrefix = `<sub>reported by [reviewdog](https://github.com/friedemannf/reviewdog) :dog:</sub><br>`

BodyPrefix is prefix text of comment body.

Variables

This section is empty.

Functions

func MarkdownComment

func MarkdownComment(c *reviewdog.Comment) string

MarkdownComment creates comment body markdown.

Types

type PostedComments

type PostedComments map[string]map[int][]string

`path` to `position`(Lnum for new file) to comment `body`s

func (PostedComments) AddPostedComment

func (p PostedComments) AddPostedComment(path string, lineNum int, body string)

AddPostedComment adds a posted comment.

func (PostedComments) DebugLog

func (p PostedComments) DebugLog()

DebugLog outputs posted comments as log for debugging.

func (PostedComments) IsPosted

func (p PostedComments) IsPosted(c *reviewdog.Comment, lineNum int, body string) bool

IsPosted returns true if a given comment has been posted in code review service already, otherwise returns false. It sees comments with same path, same position, and same body as same comments.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL