Skip to content

Commit c13c5a1

Browse files
🌟 [Major]: Issue data parser ready (#2)
## Description - Update readme - With readme provided, and the functionality working, its the first release of the action. ## Type of change <!-- Use the check-boxes [x] on the options that are relevant. --> - [ ] 📖 [Docs] - [ ] 🪲 [Fix] - [ ] 🩹 [Patch] - [ ] ⚠️ [Security fix] - [ ] 🚀 [Feature] - [x] 🌟 [Breaking change] ## Checklist <!-- Use the check-boxes [x] on the options that are relevant. --> - [x] I have performed a self-review of my own code - [x] I have commented my code, particularly in hard-to-understand areas
1 parent a5c74a7 commit c13c5a1

1 file changed

Lines changed: 68 additions & 14 deletions

File tree

README.md

Lines changed: 68 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -9,32 +9,86 @@ Bases itself on the definitions of GitHub Issue Forms:
99

1010
## Usage
1111

12-
### Inputs
12+
Provided the following issue body:
1313

14-
### Secrets
14+
```md
15+
### Name
1516

16-
### Outputs
17+
Name provided in the issue.
18+
19+
### Language
20+
21+
PowerShell
22+
23+
### Rationale
24+
25+
I need the
26+
<!-- This is
27+
a comment --> data parsed
28+
29+
### OS
30+
31+
- [ ] macOS
32+
- [x] Ubuntu
33+
- [x] Windows
34+
35+
```
1736

18-
The data structure that is returned is a JSON object that contains the following properties:
37+
This action returns the following JSON object:
1938

2039
```json
2140
{
22-
"<header1>": "<value1>", // input
23-
"<header2>": "<value2>", // dropdown
24-
"<header3>": "<value3.1>\n<value3.2>\n<value3.3>", // textarea
25-
"<header4>": { // checkbox
26-
"<valuename>": true,
27-
"<valuename>": false
41+
"Name": "Name provided in the issue.", // input
42+
"Language": "PowerShell", // dropdown
43+
"Rationale": "I need the\ndata parsed", // textarea
44+
"OS": { // checkbox
45+
"macOS": false,
46+
"Ubuntu": true,
47+
"Windows": true
2848
}
2949
}
3050
```
3151

52+
### Inputs
53+
54+
| Name | Description | Default | Required |
55+
| ---- | ----------- | ------- | -------- |
56+
| IssueBody | The body of the issue | `${{ github.event.issue.body }}` | false |
57+
58+
### Outputs
59+
60+
| Name | Description |
61+
| ---- | ----------- |
62+
| data | The parsed JSON object |
63+
3264
### Example
3365

3466
```yaml
35-
Example here
36-
```
67+
name: Example workflow
68+
on:
69+
issues:
70+
types:
71+
- opened
72+
- edited
73+
74+
permissions:
75+
contents: read
3776

38-
## Inspiration
77+
jobs:
78+
assign:
79+
name: Process issue
80+
runs-on: ubuntu-latest
81+
steps:
82+
- name: Get-IssueFormData
83+
id: Get-IssueFormData
84+
uses: PSModule/Get-IssueFormData@v0
3985

40-
- [zentered/issue-forms-body-parser](https://github.com/zentered/issue-forms-body-parser)
86+
- name: Print data
87+
shell: pwsh
88+
env:
89+
data: ${{ steps.Get-IssueFormData.outputs.data }}
90+
run: |
91+
$data = $env:data | ConvertFrom-Json
92+
Write-Output $data
93+
94+
```

0 commit comments

Comments
 (0)