]> source.dussan.org Git - gitea.git/commitdiff
Stop running hooks on pr merge (#6963)
authorzeripath <art27@cantab.net>
Fri, 17 May 2019 12:41:01 +0000 (13:41 +0100)
committerLauris BH <lauris@nix.lv>
Fri, 17 May 2019 12:41:01 +0000 (15:41 +0300)
* Stop running hooks on pr merge

* Remove SSH_ORIGINAL_COMMAND from the pushing environment

models/helper_environment.go

index 283584cc5238dc290f94adcd3f2559cb22bbd6b9..737a9a68c3a36b709e1893ccc78727181fe240a5 100644 (file)
@@ -19,6 +19,8 @@ func PushingEnvironment(doer *User, repo *Repository) []string {
 
        sig := doer.NewGitSig()
 
+       // We should add "SSH_ORIGINAL_COMMAND=gitea-internal",
+       // once we have hook and pushing infrastructure working correctly
        return append(os.Environ(),
                "GIT_AUTHOR_NAME="+sig.Name,
                "GIT_AUTHOR_EMAIL="+sig.Email,
@@ -30,7 +32,6 @@ func PushingEnvironment(doer *User, repo *Repository) []string {
                EnvPusherName+"="+doer.Name,
                EnvPusherID+"="+fmt.Sprintf("%d", doer.ID),
                ProtectedBranchRepoID+"="+fmt.Sprintf("%d", repo.ID),
-               "SSH_ORIGINAL_COMMAND=gitea-internal",
        )
 
 }