Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: stg import --reject should create empty commit #472

Closed
wants to merge 1 commit into from

Commits on Jul 15, 2024

  1. fix: stg import --reject should create empty commit

    When trying to import a patch that does not apply cleanly, and using
    --reject option, stg should apply what it can, leave the rest in .rej
    files, and create an empty commit. The work to apply the patch is
    outsourced to "git apply --reject" which exits with status code 1 if
    patch is applied partially and it is treated as error by stg import.
    
    Fix the issue by treating exit codes less than 128 from "git apply
    --reject" as success (128 signals hard error).
    
    Also add a test case and fix up documentation for "stg import".
    
    Closes: stacked-git#471
    
    Signed-off-by: Dmitry Torokhov <dtor@google.com>
    dtor committed Jul 15, 2024
    Configuration menu
    Copy the full SHA
    4e6c20a View commit details
    Browse the repository at this point in the history