MCPcopy
hub / github.com/desktop/desktop / createLFSProgressFile

Function createLFSProgressFile

app/src/lib/progress/lfs.ts:7–17  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

5
6/** Create the Git LFS progress reporting file and return the path. */
7export async function createLFSProgressFile(): Promise<string> {
8 const path = await getTempFilePath('GitHubDesktop-lfs-progress')
9
10 // getTempFilePath will take care of creating the directory, we only need
11 // to make sure the file exists as well. We use `wx` to throw if the file
12 // already exists since we don't expect it to given that getTempFilePath
13 // creates a random path.
14 await open(path, 'wx').then(f => f.close())
15
16 return path
17}
18
19// The regex for parsing LFS progress lines. See
20// https://github.com/git-lfs/git-lfs/blob/dce20b0d18213d720ff2897267e68960d296eb5e/docs/man/git-lfs-config.5.ronn

Callers 1

Calls 3

getTempFilePathFunction · 0.90
openFunction · 0.85
closeMethod · 0.65

Tested by

no test coverage detected