diffutils

package
v1.1.4 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2021 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrNoNewFile represents error which there are no expected new file line.
	ErrNoNewFile = errors.New("no expected new file line") // +++ newfile
	// ErrNoHunks represents error which there are no expected hunks.
	ErrNoHunks = errors.New("no expected hunks") // @@ -1,3 +1,4 @@
)

Functions

func FilterFileDiffs

func FilterFileDiffs(fileDiffs []*diffreviewer.FileDiff) []*diffreviewer.FileDiff

func ParseMultiFile

func ParseMultiFile(r io.Reader) ([]*diffreviewer.FileDiff, error)

ParseMultiFile parses a multi-file unified diff.

Types

type ErrInvalidHunkRange

type ErrInvalidHunkRange struct {
	// contains filtered or unexported fields
}

ErrInvalidHunkRange represents invalid line of hunk range. @@ -1,3 +1,4 @@

func (*ErrInvalidHunkRange) Error

func (e *ErrInvalidHunkRange) Error() string

Jump to

Keyboard shortcuts

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