Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Steinhardt <psteinhardt@gitlab.com>2021-01-13 12:59:44 +0300
committerPatrick Steinhardt <psteinhardt@gitlab.com>2021-01-26 10:07:59 +0300
commit16af76ac3004eee3ed9a92e19b3769e73f610088 (patch)
treeb3fdfd37b683c29d397d86135eac0dde0952f252 /internal/git2go
parent232df1394c114a6ef2d844d572e0493bf4a6e60d (diff)
git2go: Implement handling of AllowConflicts for UserMergeToRef
While we ported the UserMergeToRef RPC to Go, a new flag "allow_conflicts" was added to its request. What it does is that instead of raising an error when there's any conflict, the RPC will now commit the conflicting file together with its conflict markers. Given that both efforts kind of crossed, the parameter isn't supported by the Go implementation nowadays. This commit lays the groundwork to support it.
Diffstat (limited to 'internal/git2go')
-rw-r--r--internal/git2go/merge.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/internal/git2go/merge.go b/internal/git2go/merge.go
index 7659930a1..e92856810 100644
--- a/internal/git2go/merge.go
+++ b/internal/git2go/merge.go
@@ -37,6 +37,9 @@ type MergeCommand struct {
Ours string `json:"ours"`
// Theirs is the commit into which ours is to be merged.
Theirs string `json:"theirs"`
+ // AllowConflicts controls whether conflicts are allowed. If they are,
+ // then conflicts will be committed as part of the result.
+ AllowConflicts bool `json:"allow_conflicts"`
}
// MergeResult contains results from a merge.