diff options
Diffstat (limited to 'helperPatches.go')
| -rw-r--r-- | helperPatches.go | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/helperPatches.go b/helperPatches.go index c09730a..846ad46 100644 --- a/helperPatches.go +++ b/helperPatches.go @@ -134,32 +134,6 @@ func findCommitBySubject(subject string) (string, error) { return "", fmt.Errorf("no commit found for subject: %s", subject) } -func isPatchIdApplied(patch *forgepb.Patch) error { - repo := me.forge.FindByGoPath(patch.Namespace) - if repo == nil { - return log.Errorf("could not find repo %s", patch.Namespace) - } - - comment := cleanSubject(patch.Comment) - - os.Chdir(repo.GetFullPath()) - newhash, err := findCommitBySubject(comment) - if err != nil { - return log.Errorf("patch: not found hash: %s %s %s %s %v", patch.CommitHash, patch.Namespace, comment, newhash, err) - } - - patchId, err := repo.FindPatchIdByHash(newhash) - if err != nil { - return err - } - - patch.PatchId = patchId - patch.NewHash = newhash - - log.Infof("%s %s patch: found hash: %s %s\n", patch.CommitHash, newhash, patch.Namespace, comment) - return nil -} - // returns true if PB changed func setNewCommitHash(patch *forgepb.Patch) error { repo := me.forge.FindByGoPath(patch.Namespace) |
