MCPcopy
hub / github.com/git-lfs/git-lfs / TempFile

Function TempFile

lfs/util.go:236–238  ·  view source on GitHub ↗

TempFile creates a temporary file in the temporary directory specified by the configuration that has the proper permissions for the repository. On success, it returns an open, non-nil *os.File, and the caller is responsible for closing and/or removing it. On failure, the temporary file is automati

(cfg *config.Configuration, pattern string)

Source from the content-addressed store, hash-verified

234// This function is designed to handle only temporary files that will be renamed
235// into place later somewhere within the Git repository.
236func TempFile(cfg *config.Configuration, pattern string) (*os.File, error) {
237 return tools.TempFile(cfg.TempDir(), pattern, cfg)
238}

Callers 4

mergeProcessInputFunction · 0.92
copyToTempMethod · 0.70
pipeExtensionsFunction · 0.70
CopyFileContentsFunction · 0.70

Calls 2

TempFileFunction · 0.92
TempDirMethod · 0.45

Tested by

no test coverage detected