use of org.apache.sling.tooling.lc.jira.IssueFinder in project sling by apache.
the class LaunchpadComparer method outputFormatted.
private static void outputFormatted(Map.Entry<ArtifactKey, VersionChange> e) {
ArtifactKey artifact = e.getKey();
VersionChange versionChange = e.getValue();
System.out.format(" %-30s : %-55s : %s -> %s%n", artifact.getGroupId(), artifact.getArtifactId(), versionChange.getFrom(), versionChange.getTo());
if (!artifact.getGroupId().equals("org.apache.sling")) {
return;
}
SvnChangeLogFinder svn = new SvnChangeLogFinder();
String fromTag = artifact.getArtifactId() + "-" + versionChange.getFrom();
String toTag = artifact.getArtifactId() + "-" + versionChange.getTo();
try {
List<String> issues = svn.getChanges(fromTag, toTag).stream().map(LaunchpadComparer::toJiraKey).filter(k -> k != null).collect(Collectors.toList());
IssueFinder issueFinder = new IssueFinder();
issueFinder.findIssues(issues).forEach(i -> System.out.format(" %-10s - %s%n", i.getKey(), i.getSummary()));
} catch (SVNException | IOException e1) {
System.err.println("Failed retrieving changes : " + e1.getMessage());
}
}
Aggregations