Documentation
¶
Index ¶
- type BackportArgs
- type BackportCommandResult
- type BackportOutput
- type CommitInfo
- type CommitSignature
- type FoundMergeBase
- type GetCommitsArgs
- type GetCommitsOutput
- type GetFilesArgs
- type GetFilesOutput
- type GetMergeBaseArgs
- type GetMergeBaseOutput
- type GetModifiedFilesArgs
- type GetModifiedFilesOutput
- type GetModifiedFilesPattern
- type GetModifiedFilesRegexpMatchesArgs
- type GetModifiedFilesRegexpMatchesOutput
- type LinearRebaseArgs
- type LinearRebaseOutput
- type LinearRebaseResult
- type LsRefsArgs
- type LsRefsOutput
- type ModificationStatus
- type ModifiedFile
- type ModifiedFilePattern
- type ModifiedFilePatternMatch
- type PushSquashCherryPickResult
- type RefInfo
- type RefUpdateCommand
- type SquashCherryPickArgs
- type SquashCherryPickOutput
- type SquashCommand
- type SquashCommandResult
- type SquashPushArgs
- type SquashPushOutput
- type UpdateRefsArgs
- type UpdateRefsOutput
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BackportArgs ¶
type BackportCommandResult ¶
type BackportOutput ¶
type BackportOutput struct { CommandResults []BackportCommandResult `json:"commandResults"` FetchDebugInfos []*debug.FetchDebugInfo `json:"fetchDebugInfos"` PushDebugInfo *debug.PushDebugInfo `json:"pushDebugInfo"` Error string `json:"error,omitempty"` }
func Backport ¶
func Backport(ctx context.Context, client *http.Client, args BackportArgs) BackportOutput
type CommitInfo ¶
type CommitInfo struct { // Hash is the commit hash. Hash string `json:"hash"` // Author is the author of the commit. Author CommitSignature `json:"author"` // Committer is the committer of the commit. Committer CommitSignature `json:"committer"` // Message is the commit message. Message string `json:"message"` // TreeHash is the hash of the tree object of the commit. TreeHash string `json:"treeHash"` // ParentHashes are the hashes of the parent commits. ParentHashes []string `json:"parentHashes"` }
func FetchCommits ¶
type CommitSignature ¶
type FoundMergeBase ¶
type GetCommitsArgs ¶
type GetCommitsOutput ¶
type GetCommitsOutput struct { Commits []*CommitInfo `json:"commits"` DebugInfo debug.FetchDebugInfo `json:"debugInfo"` Error string `json:"error,omitempty"` }
func GetCommits ¶
func GetCommits(ctx context.Context, client *http.Client, args GetCommitsArgs) GetCommitsOutput
type GetFilesArgs ¶
type GetFilesOutput ¶
type GetFilesOutput struct { Files map[string]string `json:"files"` FetchDebugInfo *debug.FetchDebugInfo `json:"fetchDebugInfo"` BlobFetchDebugInfo *debug.FetchDebugInfo `json:"blobFetchDebugInfo"` Error string `json:"error,omitempty"` }
func GetFiles ¶
func GetFiles(ctx context.Context, client *http.Client, args GetFilesArgs) GetFilesOutput
type GetMergeBaseArgs ¶
type GetMergeBaseOutput ¶
type GetMergeBaseOutput struct { MergeBases []FoundMergeBase `json:"mergeBases"` FetchDebugInfos []*debug.FetchDebugInfo `json:"fetchDebugInfos"` Error string `json:"error,omitempty"` }
func GetMergeBase ¶
func GetMergeBase(ctx context.Context, client *http.Client, args GetMergeBaseArgs) GetMergeBaseOutput
type GetModifiedFilesArgs ¶
type GetModifiedFilesOutput ¶
type GetModifiedFilesOutput struct { Files []string `json:"files"` DebugInfo debug.FetchDebugInfo `json:"debugInfo"` Error string `json:"error,omitempty"` }
func GetModifiedFiles ¶
func GetModifiedFiles(ctx context.Context, client *http.Client, args GetModifiedFilesArgs) GetModifiedFilesOutput
type GetModifiedFilesPattern ¶
type GetModifiedFilesRegexpMatchesArgs ¶
type GetModifiedFilesRegexpMatchesArgs struct { RepoURL string `json:"repoURL"` CommitHash1 string `json:"commitHash1"` CommitHash2 string `json:"commitHash2"` Patterns map[string]GetModifiedFilesPattern `json:"patterns"` }
type GetModifiedFilesRegexpMatchesOutput ¶
type GetModifiedFilesRegexpMatchesOutput struct { Files []*ModifiedFile `json:"files"` FetchDebugInfo *debug.FetchDebugInfo `json:"fetchDebugInfo"` BlobFetchDebugInfo *debug.FetchDebugInfo `json:"blobFetchDebugInfo"` Error string `json:"error,omitempty"` }
func GetModifiedFilesRegexpMatches ¶
func GetModifiedFilesRegexpMatches(ctx context.Context, client *http.Client, args GetModifiedFilesRegexpMatchesArgs) GetModifiedFilesRegexpMatchesOutput
type LinearRebaseArgs ¶
type LinearRebaseOutput ¶
type LinearRebaseOutput struct { LinearRebaseResults []*LinearRebaseResult `json:"linearRebaseResults"` LsRefsDebugInfo *debug.LsRefsDebugInfo `json:"lsRefsDebugInfo"` FetchDebugInfos []*debug.FetchDebugInfo `json:"fetchDebugInfos"` PushDebugInfos *debug.PushDebugInfo `json:"pushDebugInfo"` Error string `json:"error,omitempty"` }
func LinearRebase ¶
func LinearRebase(ctx context.Context, client *http.Client, args LinearRebaseArgs) LinearRebaseOutput
type LinearRebaseResult ¶
type LinearRebaseResult struct { Ref string `json:"ref"` CommitHash string `json:"commitHash"` ConflictOpenFiles []string `json:"conflictOpenFiles"` ConflictResolvedFiles []string `json:"conflictResolvedFiles"` BinaryConflictFiles []string `json:"binaryConflictFiles"` NonFileConflictFiles []string `json:"nonFileConflictFiles"` }
type LsRefsArgs ¶
type LsRefsOutput ¶
type LsRefsOutput struct { Refs []*RefInfo `json:"refs"` DebugInfo debug.LsRefsDebugInfo `json:"debugInfo"` Error string `json:"error,omitempty"` }
func LsRefs ¶
func LsRefs(ctx context.Context, client *http.Client, args LsRefsArgs) LsRefsOutput
type ModificationStatus ¶
type ModificationStatus string
const ( ModificationStatusAdded ModificationStatus = "ADDED" ModificationStatusDeleted ModificationStatus = "DELETED" ModificationStatusModified ModificationStatus = "MODIFIED" )
type ModifiedFile ¶
type ModifiedFile struct { Path string `json:"path"` Status ModificationStatus `json:"status"` Matches map[string]*ModifiedFilePatternMatch `json:"matches,omitempty"` }
type ModifiedFilePattern ¶
type RefInfo ¶
type RefInfo struct { // Name is the name of the ref. Name string `json:"name"` // Hash is the hash of the object that the ref points to. // // This can be "unborn" if the ref is not created. See man 5 gitprotocol-v2. Hash string `json:"hash"` // PeeledHash is the hash of the object that the ref points to, if the ref is a tag. PeeledHash string `json:"peeledHash,omitempty"` // SymbolicTarget is the target of the symbolic ref, if the ref is symbolic. SymbolicTarget string `json:"symbolicTarget,omitempty"` }
type RefUpdateCommand ¶
type RefUpdateCommand struct { // RefName is a reference name to update (e.g. "refs/heads/main"). RefName string `json:"refName"` // OldHash is a hash of the reference before the update. // // There is a difference between zero hash and empty string: // // * If this is a zero hash, it means that the reference should be newly created (it should // not exist. // * If this is an empty string, it means that the reference is updated unconditionally // (force update). // // Note that, at the git-transport level, everything is a force update. The client should // check if the reference being updated is fast-forwardable if they want such behavior. OldHash string `json:"oldHash"` // NewHash is a hash of the reference after the update. NewHash string `json:"newHash"` }
type SquashCherryPickArgs ¶
type SquashCherryPickArgs struct { RepoURL string `json:"repoURL"` CherryPickFrom string `json:"cherryPickFrom"` CherryPickTo string `json:"cherryPickTo"` CherryPickBase string `json:"cherryPickBase"` CommitMessage string `json:"commitMessage"` Author string `json:"author"` AuthorEmail string `json:"authorEmail"` AuthorTime string `json:"authorTime"` Committer string `json:"committer"` CommitterEmail string `json:"committerEmail"` CommitterTime string `json:"committerTime"` Ref string `json:"ref"` ConflictRef string `json:"conflictRef"` CurrentRefHash string `json:"currentRefHash"` AbortOnConflict bool `json:"abortOnConflict"` }
type SquashCherryPickOutput ¶
type SquashCherryPickOutput struct { CommitHash string `json:"commitHash"` CherryPickedFiles []string `json:"cherryPickedFiles"` ConflictOpenFiles []string `json:"conflictOpenFiles"` ConflictResolvedFiles []string `json:"conflictResolvedFiles"` BinaryConflictFiles []string `json:"binaryConflictFiles"` NonFileConflictFiles []string `json:"nonFileConflictFiles"` FetchDebugInfo debug.FetchDebugInfo `json:"fetchDebugInfo"` BlobFetchDebugInfo *debug.FetchDebugInfo `json:"blobFetchDebugInfo"` PushDebugInfo *debug.PushDebugInfo `json:"pushDebugInfo"` Error string `json:"error,omitempty"` }
func SquashCherryPick ¶
func SquashCherryPick(ctx context.Context, client *http.Client, args SquashCherryPickArgs) SquashCherryPickOutput
type SquashCommand ¶
type SquashCommand struct { CommitHashStart string `json:"commitHashStart"` CommitHashEnd string `json:"commitHashEnd"` CommitMessage string `json:"commitMessage"` Committer string `json:"committer"` CommitterEmail string `json:"committerEmail"` CommitterTime string `json:"committerTime"` Author string `json:"author"` AuthorEmail string `json:"authorEmail"` AuthorTime string `json:"authorTime"` }
type SquashCommandResult ¶
type SquashPushArgs ¶
type SquashPushArgs struct { RepoURL string `json:"repoURL"` BaseCommitHash string `json:"baseCommitHash"` SquashCommands []SquashCommand `json:"squashCommands"` Ref string `json:"ref"` CurrentRefHash string `json:"currentRefHash"` }
type SquashPushOutput ¶
type SquashPushOutput struct { CommandResults []SquashCommandResult `json:"commandResults"` FetchDebugInfos []*debug.FetchDebugInfo `json:"fetchDebugInfos"` PushDebugInfo *debug.PushDebugInfo `json:"pushDebugInfo"` Error string `json:"error,omitempty"` }
func SquashPush ¶
func SquashPush(ctx context.Context, client *http.Client, args SquashPushArgs) SquashPushOutput
type UpdateRefsArgs ¶
type UpdateRefsArgs struct { RepoURL string `json:"repoURL"` RefUpdateCommands []RefUpdateCommand `json:"refUpdateCommands"` }
type UpdateRefsOutput ¶
type UpdateRefsOutput struct { PushDebugInfo *debug.PushDebugInfo `json:"pushDebugInfo"` Error string `json:"error,omitempty"` }
func UpdateRefs ¶
func UpdateRefs(ctx context.Context, client *http.Client, args UpdateRefsArgs) UpdateRefsOutput
Source Files
¶
Click to show internal directories.
Click to hide internal directories.