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

Refactor merge/update git command calls (#23366) #23544

Merged

Commits on Mar 17, 2023

  1. Refactor merge/update git command calls (go-gitea#23366)

    Follow go-gitea#22568
    
    * Remove unnecessary ToTrustedCmdArgs calls 
        * the FAQ in  go-gitea#22678
    * Quote: When using ToTrustedCmdArgs, the code will be very complex (see
    the changes for examples). Then developers and reviewers can know that
    something might be unreasonable.
    * The `signArg` couldn't be empty, it's either `-S{keyID}` or
    `--no-gpg-sign`.
    * Use `signKeyID` instead, add comment "empty for no-sign, non-empty to
    sign"
    * 5-line code could be extracted to a common `NewGitCommandCommit()` to
    handle the `signKeyID`, but I think it's not a must, current code is
    clear enough.
    wxiaoguang committed Mar 17, 2023
    Configuration menu
    Copy the full SHA
    c47ef82 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    8db1fe3 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    9ffbe2d View commit details
    Browse the repository at this point in the history