Something went wrong. Try again.
Monorepo for Tangled tangled.org
Something went wrong. Try again.
1.6 kB · 50 lines
Go
at sv-fe
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT.
package org_tangled
// schema: org.tangled.temp.git.getEntry
import ( "context"
"github.com/bluesky-social/indigo/lex/util" shtangledtypes "tangled.org/core/api/tangled")
const ( TempGitGetEntryNSID = "org.tangled.temp.git.getEntry")
// TempGitGetEntry_Output is the output of a org.tangled.temp.git.getEntry call.type TempGitGetEntry_Output struct { LastCommit *shtangledtypes.GitTempDefs_Commit `json:"lastCommit,omitempty" cborgen:"lastCommit,omitempty"` Mode string `json:"mode" cborgen:"mode"` // name: The file name Name string `json:"name" cborgen:"name"` Oid string `json:"oid" cborgen:"oid"` // size: Blob size Size int64 `json:"size" cborgen:"size"` // submodule: Submodule information if path is a submodule Submodule *shtangledtypes.GitTempDefs_Submodule `json:"submodule,omitempty" cborgen:"submodule,omitempty"`}
// TempGitGetEntry calls the XRPC method "org.tangled.temp.git.getEntry".//// path: path of the entity// ref: Git revision (branch, tag, or commit id)// repo: DID of the repositoryfunc TempGitGetEntry(ctx context.Context, c util.LexClient, path string, ref string, repo string) (*TempGitGetEntry_Output, error) { var out TempGitGetEntry_Output
params := map[string]interface{}{} params["path"] = path if ref != "" { params["ref"] = ref } params["repo"] = repo if err := c.LexDo(ctx, util.Query, "", "org.tangled.temp.git.getEntry", params, nil, &out); err != nil { return nil, err }
return &out, nil}