Skip to main content

run_upload_interactive

Function run_upload_interactive 

Source
pub fn run_upload_interactive(
    plan: &UploadPlan,
    global_prefix: &[OsString],
    directory: &Path,
    real_git: &Path,
    environment: &[(OsString, OsString)],
    overlay: &[(OsString, OsString)],
    diagnostics: &mut dyn Write,
) -> Option<i32>
Expand description

What: Run the upload as a child with the caller’s streams and return the status to stop with, or nothing when it succeeded. Why: The parent saw the child end, so it prints the explanation after the program’s own output; the push is not started. A signal sent to the wrapper is relayed to the child, so stopping the wrapper stops the upload. A push that also pushes submodules gets a notice, because their objects are not part of this upload.

In TS you’d write (pseudocode):

const code = await spawn('git-lfs', plan.arguments(), { stdio: 'inherit' }); if (code) { print(failedMessage(...)); return code; }