From 550fe573e22b121891f52246e95c298c2a15d823 Mon Sep 17 00:00:00 2001 From: CMGS Date: Thu, 3 Sep 2026 15:24:35 +0800 Subject: [PATCH] review(wire): GitFileStatus ahead of the response type it serves --- protocol/wire/frame.go | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/protocol/wire/frame.go b/protocol/wire/frame.go index a7e0cc9b..54345a79 100644 --- a/protocol/wire/frame.go +++ b/protocol/wire/frame.go @@ -617,6 +617,13 @@ type Event struct { func (Event) RespType() string { return "event" } +// GitFileStatus is one porcelain-v2 entry; Staged/Unstaged are XY status codes. +type GitFileStatus struct { + Path string `json:"path"` + Staged string `json:"staged"` + Unstaged string `json:"unstaged"` +} + // GitStatusResult answers GitStatus. type GitStatusResult struct { Branch string `json:"branch"` @@ -628,13 +635,6 @@ type GitStatusResult struct { func (GitStatusResult) RespType() string { return "git_status_result" } -// GitFileStatus is one porcelain-v2 entry; Staged/Unstaged are XY status codes. -type GitFileStatus struct { - Path string `json:"path"` - Staged string `json:"staged"` - Unstaged string `json:"unstaged"` -} - // GitCommitResult answers GitCommit with the new commit hash. type GitCommitResult struct { Hash string `json:"hash"`