Skip to content

Commit

Permalink
feat: add issue-body default (#47)
Browse files Browse the repository at this point in the history
* feat: add issue-body default

closes #46

* doc: updating issue-body references

closes #46

* doc: removing issue-body from default usage

Co-authored-by: Hervé Le Meur <[email protected]>

* doc: adding note about issue-body

Co-authored-by: Hervé Le Meur <[email protected]>
  • Loading branch information
joshjohanning and lemeurherve authored Oct 20, 2022
1 parent de423fc commit 741688b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 12 deletions.
13 changes: 1 addition & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ Use this action to convert issues into a unified JSON structure. Read the [Codel
- uses: stefanbuck/github-issue-parser@v3
id: issue-parser
with:
issue-body: ${{ github.event.issue.body }} # required
template-path: .github/ISSUE_TEMPLATE/bug-report.yml # optional but recommended

- run: cat ${HOME}/issue-parser-result.json
Expand All @@ -20,17 +19,7 @@ Use this action to convert issues into a unified JSON structure. Read the [Codel
FAVORITE_DISH: ${{ steps.issue-parser.outputs.issueparser_favorite_dish }}
```
## Migrate from v2 to v3
```diff
-- uses: stefanbuck/github-issue-parser@v2
+- uses: stefanbuck/github-issue-parser@v3
id: issue-parser
with:
+ issue-body: ${{ github.event.issue.body }}
template-path: .github/ISSUE_TEMPLATE/bug-report.yml
```
The text to be parsed can be set explicitly using `issue-body` input, otherwise it can be left to use the default value of `${{ github.event.issue.body }}`.

## Example

Expand Down
1 change: 1 addition & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ inputs:
issue-body:
required: true
description: 'Issue body to parse'
default: ${{ github.event.issue.body }}
outputs:
jsonString:
description: 'JSON string'
Expand Down

0 comments on commit 741688b

Please sign in to comment.