Skip to content

Commit

Permalink
fixup: correct details markdown for dependency metadata
Browse files Browse the repository at this point in the history
  • Loading branch information
lemeurherve authored Feb 10, 2024
1 parent 89790c9 commit 5113b7c
Showing 1 changed file with 3 additions and 10 deletions.
13 changes: 3 additions & 10 deletions lib/github.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,7 @@ export default {
createStatus: async (owner, repo, head_sha, entries) => {
const github = await getRestClient();

let summary = entries.map(entry => `- [${entry.artifactId}](${entry.url})`).join("\n")

summary += "```xml\n"
summary += "<dependency>\n"
summary += ` <groupId>${entries[0].groupId}</groupId>` + "\n"
summary += ` <artifactId>${entries[0].artifactId}</artifactId>` + "\n"
summary += ` <version>${entries[0].version}</version>` + "\n"
summary += "</dependency>\n"
summary += "```\n"
const metadata = `<pre>&#xA;<dependency>&#xA; <groupId>${entries[0].groupId}</groupId>&#xA; <artifactId>${entries[0].artifactId}</artifactId>&#xA; <version>${entries[0].version}</version>&#xA;</dependency>&#xA;`

return github.rest.checks.create({
owner,
Expand All @@ -59,7 +51,8 @@ export default {
details_url: entries[0].url,
output: {
title: `Deployed version ${entries[0].version} to Incrementals`,
summary: summary
summary: entries.map(entry => `- [${entry.artifactId}](${entry.url})`).join("\n"),
text: metadata
}
});
}
Expand Down

0 comments on commit 5113b7c

Please sign in to comment.