https://github.com/psmodule/get-issueformdata
Get the data from a issue that was generated based on a issue form
https://github.com/psmodule/get-issueformdata
Last synced: 23 days ago
JSON representation
Get the data from a issue that was generated based on a issue form
- Host: GitHub
- URL: https://github.com/psmodule/get-issueformdata
- Owner: PSModule
- License: mit
- Created: 2024-08-06T22:28:30.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2026-02-17T12:00:36.000Z (about 1 month ago)
- Last Synced: 2026-02-17T17:42:51.479Z (about 1 month ago)
- Language: PowerShell
- Homepage: https://github.com/PSModule/Get-IssueFormData
- Size: 53.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Get-IssueFormData
Reads the body of an issue and parses it into a JSON object.
Bases itself on the definitions of GitHub Issue Forms:
- [Syntax for issue forms | GitHub Docs](https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms)
- [Syntax for GitHub's form schema](https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema)
## Usage
Provided the following issue body:
```md
### Name
Name provided in the issue.
### Language
PowerShell
### Rationale
I need the
data parsed
### OS
- [ ] macOS
- [x] Ubuntu
- [x] Windows
```
This action returns the following JSON object:
```json
{
"Name": "Name provided in the issue.", // input
"Language": "PowerShell", // dropdown
"Rationale": "I need the\ndata parsed", // textarea
"OS": { // checkbox
"macOS": false,
"Ubuntu": true,
"Windows": true
}
}
```
### Inputs
| Name | Description | Default | Required |
| ---- | ----------- | ------- | -------- |
| IssueBody | The body of the issue, if not provided it will use the body of the issue that triggered the workflow. | `${{ github.event.issue.body }}` | false |
### Outputs
| Name | Description |
| ---- | ----------- |
| data | The parsed JSON object |
### Example
```yaml
name: Example workflow
on:
issues:
types:
- opened
- edited
permissions:
contents: read
jobs:
assign:
name: Process issue
runs-on: ubuntu-latest
steps:
- name: Get-IssueFormData
id: Get-IssueFormData
uses: PSModule/Get-IssueFormData@v1
- name: Print data
shell: pwsh
env:
data: ${{ steps.Get-IssueFormData.outputs.data }}
run: |
$data = $env:data | ConvertFrom-Json
Write-Output $data
```
## Alternatives
- [github/issue-parser](https://github.com/github/issue-parser)
- [issue-ops/parser](https://github.com/issue-ops/parser)
- [peter-murray/issue-forms-body-parser](https://github.com/peter-murray/issue-forms-body-parser)
- [peter-murray/issue-body-parser-action](https://github.com/peter-murray/issue-body-parser-action)