diff --git a/pr/githubapi/pull_request.go b/pr/githubapi/pull_request.go index 058cbbb..4f2c811 100644 --- a/pr/githubapi/pull_request.go +++ b/pr/githubapi/pull_request.go @@ -35,7 +35,14 @@ func (client *githubClient) ListChangedPortsAndFiles(owner, repo string, number portfileRegexp := regexp.MustCompile(`[^\._/][^/]*/([^/]+)/Portfile`) // Ignore hidden and _* top directories for _, file := range allFiles { - if match := portfileRegexp.FindStringSubmatch(*file.Filename); match != nil { + match := portfileRegexp.FindStringSubmatch(*file.Filename) + if match != nil { + if *file.Status == "renamed" { + match = portfileRegexp.FindStringSubmatch(*file.PreviousFilename) + if match == nil { + continue + } + } ports = append(ports, match[1]) commitFiles = append(commitFiles, file) }