MCPcopy Index your code
hub / github.com/cloudquery/cloudquery / UploadFile

Function UploadFile

cli/internal/hub/util.go:70–72  ·  view source on GitHub ↗
(uploadURL, localPath string)

Source from the content-addressed store, hash-verified

68}
69
70func UploadFile(uploadURL, localPath string) error {
71 return UploadFileWithContentType(context.Background(), uploadURL, localPath, "application/octet-stream")
72}
73
74func UploadFileWithContentType(ctx context.Context, uploadURL, localPath, contentType string) error {
75 file, err := os.Open(localPath)

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected