diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2020-09-15 18:05:35 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2020-09-15 19:34:30 +0200 |
| commit | 712de1c63d9db97c81af68cd0dc4372c53d2e57a (patch) | |
| tree | ae1761fec52c3ae4ddd003a4130ddbda8d0a2d69 /vendor/github.com/sourcegraph/go-diff/diff/diff.proto | |
| parent | 298a69c38dd5c8a9bbd7a022e88f4ddbcf885e16 (diff) | |
vendor/github.com/golangci/golangci-lint: update to v1.31
Diffstat (limited to 'vendor/github.com/sourcegraph/go-diff/diff/diff.proto')
| -rw-r--r-- | vendor/github.com/sourcegraph/go-diff/diff/diff.proto | 81 |
1 files changed, 0 insertions, 81 deletions
diff --git a/vendor/github.com/sourcegraph/go-diff/diff/diff.proto b/vendor/github.com/sourcegraph/go-diff/diff/diff.proto deleted file mode 100644 index 8868970f6..000000000 --- a/vendor/github.com/sourcegraph/go-diff/diff/diff.proto +++ /dev/null @@ -1,81 +0,0 @@ -syntax = "proto3"; -package diff; - -import "github.com/gogo/protobuf/gogoproto/gogo.proto"; -import "sourcegraph.com/sqs/pbtypes/timestamp.proto"; - -option (gogoproto.goproto_getters_all) = false; -option (gogoproto.unmarshaler_all) = true; -option (gogoproto.marshaler_all) = true; -option (gogoproto.sizer_all) = true; - -// A FileDiff represents a unified diff for a single file. -// -// A file unified diff has a header that resembles the following: -// -// --- oldname 2009-10-11 15:12:20.000000000 -0700 -// +++ newname 2009-10-11 15:12:30.000000000 -0700 -message FileDiff { - // the original name of the file - string OrigName = 1; - - // the original timestamp (nil if not present) - pbtypes.Timestamp OrigTime = 2; - - // the new name of the file (often same as OrigName) - string NewName = 3; - - // the new timestamp (nil if not present) - pbtypes.Timestamp NewTime = 4; - - // extended header lines (e.g., git's "new mode <mode>", "rename from <path>", etc.) - repeated string Extended = 5; - - // hunks that were changed from orig to new - repeated Hunk Hunks = 6; -} - - -// A Hunk represents a series of changes (additions or deletions) in a file's -// unified diff. -message Hunk { - // starting line number in original file - int32 OrigStartLine = 1; - - // number of lines the hunk applies to in the original file - int32 OrigLines = 2; - - // if > 0, then the original file had a 'No newline at end of file' mark at this offset - int32 OrigNoNewlineAt = 3; - - // starting line number in new file - int32 NewStartLine = 4; - - // number of lines the hunk applies to in the new file - int32 NewLines = 5; - - // optional section heading - string Section = 6; - - // 0-indexed line offset in unified file diff (including section headers); this is - // only set when Hunks are read from entire file diff (i.e., when ReadAllHunks is - // called) This accounts for hunk headers, too, so the StartPosition of the first - // hunk will be 1. - int32 StartPosition = 7; - - // hunk body (lines prefixed with '-', '+', or ' ') - bytes Body = 8; -} - -// A Stat is a diff stat that represents the number of lines added/changed/deleted. -message Stat { - // number of lines added - int32 Added = 1 [(gogoproto.jsontag) = ""]; - - // number of lines changed - int32 Changed = 2 [(gogoproto.jsontag) = ""]; - - // number of lines deleted - int32 Deleted = 3 [(gogoproto.jsontag) = ""]; -} - |
