mirror of
https://forgejo.stefka.eu/jiriks74/create-pull-request.git
synced 2025-01-18 16:01:06 +01:00
feat: output the pull request url
This commit is contained in:
parent
37b2bd1eca
commit
2465e435b9
4 changed files with 42 additions and 22 deletions
|
@ -66,8 +66,8 @@ All inputs are **optional**. If not set, sensible defaults will be used.
|
|||
|
||||
### Action outputs
|
||||
|
||||
The pull request number is output as a step output.
|
||||
Note that in order to read the step output the action step must have an id.
|
||||
The pull request number and URL are available as step outputs.
|
||||
Note that in order to read the step outputs the action step must have an id.
|
||||
|
||||
```yml
|
||||
- name: Create Pull Request
|
||||
|
@ -76,6 +76,7 @@ Note that in order to read the step output the action step must have an id.
|
|||
- name: Check outputs
|
||||
run: |
|
||||
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}"
|
||||
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"
|
||||
```
|
||||
|
||||
### Action behaviour
|
||||
|
@ -196,9 +197,10 @@ jobs:
|
|||
milestone: 1
|
||||
draft: false
|
||||
|
||||
- name: Check output
|
||||
- name: Check outputs
|
||||
run: |
|
||||
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}"
|
||||
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"
|
||||
```
|
||||
|
||||
An example based on the above reference configuration creates pull requests that look like this:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue