Registry / utility / sourcegraph-go-diff

sourcegraph-go-diff

JSON →
library0.8.0gogounverified

Go-diff provides parsing and printing of unified diffs in Go.

go get sourcegraph.com/sourcegraph/go-diff
INSTALL
IMPORT
SIG · SOURCEGRAPH-GO-DIF
S
sourcegraph-go-diff
utilitygov0.8.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

diff
sourcegraph.com/sourcegraph/go-diff

Parse a unified diff

package main import "sourcegraph.com/sourcegraph/go-diff" func main() { diffs, err := diff.Parse([]byte("--- a/file\n+++ b/file\n@@ -1 +1 @@\n-old\n+new")) if err != nil { panic(err) } _ = diffs }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.8.0latest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
6
Resources
sourcegraph-go-diff — go get sourcegraph-go-diff · libregistry