// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT. package org_tangled // schema: org.tangled.temp.git.listCommits import ( "context" "github.com/bluesky-social/indigo/lex/util" ) const ( TempGitListCommitsNSID = "org.tangled.temp.git.listCommits" ) // TempGitListCommits_Commit is a "commit" in the org.tangled.temp.git.listCommits schema. type TempGitListCommits_Commit struct { Author *GitDefs_Signature `json:"author" cborgen:"author"` Committer *GitDefs_Signature `json:"committer" cborgen:"committer"` ExtraHeaders []*TempGitListCommits_Header `json:"extraHeaders" cborgen:"extraHeaders"` Message string `json:"message" cborgen:"message"` Oid string `json:"oid" cborgen:"oid"` Parents []string `json:"parents" cborgen:"parents"` Stat *GitDefs_DiffStat `json:"stat,omitempty" cborgen:"stat,omitempty"` Tree string `json:"tree" cborgen:"tree"` } // TempGitListCommits_Header is a "header" in the org.tangled.temp.git.listCommits schema. type TempGitListCommits_Header struct { Key string `json:"key" cborgen:"key"` Value string `json:"value" cborgen:"value"` } // TempGitListCommits_Output is the output of a org.tangled.temp.git.listCommits call. type TempGitListCommits_Output struct { Commits []*TempGitListCommits_Commit `json:"commits" cborgen:"commits"` } // TempGitListCommits calls the XRPC method "org.tangled.temp.git.listCommits". // // includeStats: Diff each commit against its first parent and include a line stat // limit: Maximum number of commits to return // ranges: Commit ids or `..` ranges // repos: DIDs of the repositories to read objects from // skip: Number of matching commits to skip. A poor man's pagination. func TempGitListCommits(ctx context.Context, c util.LexClient, includeStats bool, limit int64, ranges []string, repos []string, skip int64) (*TempGitListCommits_Output, error) { var out TempGitListCommits_Output params := map[string]interface{}{} if includeStats { params["includeStats"] = includeStats } if limit != 0 { params["limit"] = limit } if len(ranges) != 0 { params["ranges"] = ranges } params["repos"] = repos if skip != 0 { params["skip"] = skip } if err := c.LexDo(ctx, util.Query, "", "org.tangled.temp.git.listCommits", params, nil, &out); err != nil { return nil, err } return &out, nil }