Merge pull request #455 from mikepenz/feature/451
Output joined list with PR IDs
This commit is contained in:
@@ -76,12 +76,13 @@ A full set list of possible output values for this action.
|
||||
|
||||
| **Output** | **Description** |
|
||||
|---------------------|---------------------------------------------------------------------------------------------------------------------------|
|
||||
| `outputs.changelog` | The built release changelog built from the merged pull requests |
|
||||
| `outputs.owner` | Specifies the owner of the repository processed |
|
||||
| `outputs.repo` | Describes the repository name, which was processed |
|
||||
| `outputs.fromTag` | Defines the `fromTag` which describes the lower bound to process pull requests for |
|
||||
| `outputs.toTag` | Defines the `toTag` which describes the upper bound to process pull request for |
|
||||
| `outputs.failed` | Defines if there was an issue with the action run, and the changelog may not have been generated correctly. [true, false] |
|
||||
| `outputs.changelog` | The built release changelog built from the merged pull requests |
|
||||
| `outputs.owner` | Specifies the owner of the repository processed |
|
||||
| `outputs.repo` | Describes the repository name, which was processed |
|
||||
| `outputs.fromTag` | Defines the `fromTag` which describes the lower bound to process pull requests for |
|
||||
| `outputs.toTag` | Defines the `toTag` which describes the upper bound to process pull request for |
|
||||
| `outputs.failed` | Defines if there was an issue with the action run, and the changelog may not have been generated correctly. [true, false] |
|
||||
| `outputs.pull_requests` | Defines a `,` joined array with all PR IDs associated with the generated changelog. |
|
||||
|
||||
|
||||
## Full Sample 🖥️
|
||||
|
||||
+6
@@ -593,6 +593,12 @@ class ReleaseNotes {
|
||||
if (!this.options.commitMode) {
|
||||
core.startGroup(`🚀 Load pull requests`);
|
||||
mergedPullRequests = yield this.getMergedPullRequests(this.octokit);
|
||||
// define the included PRs within this release as output
|
||||
core.setOutput('pull_requests', mergedPullRequests
|
||||
.map(pr => {
|
||||
return pr.number;
|
||||
})
|
||||
.join(','));
|
||||
core.endGroup();
|
||||
}
|
||||
else {
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -24,6 +24,17 @@ export class ReleaseNotes {
|
||||
if (!this.options.commitMode) {
|
||||
core.startGroup(`🚀 Load pull requests`)
|
||||
mergedPullRequests = await this.getMergedPullRequests(this.octokit)
|
||||
|
||||
// define the included PRs within this release as output
|
||||
core.setOutput(
|
||||
'pull_requests',
|
||||
mergedPullRequests
|
||||
.map(pr => {
|
||||
return pr.number
|
||||
})
|
||||
.join(',')
|
||||
)
|
||||
|
||||
core.endGroup()
|
||||
} else {
|
||||
core.startGroup(`🚀 Load commit history`)
|
||||
|
||||
Reference in New Issue
Block a user