(input, options = normalizeCloneOptions(input))
| 64 | } |
| 65 | |
| 66 | export function buildCloneCommand(input, options = normalizeCloneOptions(input)) { |
| 67 | const ref = typeof input.ref === "string" && input.ref ? ` --branch ${shell(input.ref)}` : ""; |
| 68 | const filter = options.strategy === "blobless" ? " --filter=blob:none" : ""; |
| 69 | const sparse = options.sparse.length ? " --sparse --no-checkout" : ""; |
| 70 | return `git clone --depth=1${filter}${sparse}${ref} ${shell(cloneUrl(input.repo, input.auth))} repo`; |
| 71 | } |
| 72 | |
| 73 | function run(cmd, cwd, timeoutMs = MAX_TIMEOUT_MS) { |
| 74 | return new Promise((resolveRun) => { |
no test coverage detected