You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
name: New Blog Postdescription: Create a new blog post for your Hugo site.title: "[New Blog Post] <title>"labels:
- new-blog-postbody:
- type: inputid: titleattributes:
label: Blog Post Titledescription: The title of the blog post.validations:
required: true
- type: inputid: dateattributes:
label: Post Datedescription: Date of the blog post in YYYY-MM-DD format.placeholder: "2025-01-01"validations:
required: true
- type: textareaid: descriptionattributes:
label: Descriptiondescription: A short description of the blog post.validations:
required: true
- type: inputid: linkattributes:
label: Linkdescription: The external link.placeholder: "https://www.youtube.com/embed/example"validations:
required: false
- type: textareaid: contentattributes:
label: Additional Contentdescription: Add the content for the blog post.validations:
required: false
and the following example Issue:
### Blog Post Title
Test blog post via `Actions`!
### Post Date
2025-01-01
### Description
This is a test to see if I can create new blog posts via a GitHub Issue Template!
### Link
None
### Additional Content
Testing that I can include ==Markdown== **here**!
And I get a nice editor on [GitHub.com](github.com)!! With a GFM Preview!
# Header 1
Header 1 content that should be in the `content` field
## Header 2
Header 2 content that should be in the `content` field
-[ ] Example todo
### Header 3
Header 3 content that should be in the `content` field
the parsed JSON looks like
{
"title": "Test blog post via `Actions`!",
"date": "2025-01-01",
"description": "This is a test to see if I can create new blog posts via a GitHub Issue Template!",
"content": "Testing that I can include ==Markdown== **here**!\n\nAnd I get a nice editor on [GitHub.com](github.com)!! With a GFM Preview!\n\n# Header 1\n\nHeader 1 content that should be in the `content` field\n\n## Header 2\n\nHeader 2 content that should be in the `content` field\n- [ ] Example todo",
"header_3": "Header 3 content that should be in the `content` field"
}
we can see it's
Missing the link field
Created a new header_3 field instead of preserving it inside of content
That is, the expected output should be:
{
"title": "Test blog post via `Actions`!",
"date": "2025-01-01",
"description": "This is a test to see if I can create new blog posts via a GitHub Issue Template!",
"link":'',"content": "Testing that I can include ==Markdown== **here**!\n\nAnd I get a nice editor on [GitHub.com](github.com)!! With a GFM Preview!\n\n# Header 1\n\nHeader 1 content that should be in the `content` field\n\n## Header 2\n\nHeader 2 content that should be in the `content` field\n- [ ] Example todo\n\n### Header 3\n\nHeader 3 content that should be in the `content` field",
}
The text was updated successfully, but these errors were encountered:
I didn't think to account for markdown being included in a response, so I can can definitely see where this is going wrong there. I will make some tweaks to handle that :)
The only issue I see coming up is the header_3 field example. In that case, I will need to ignore any "fields" that are not in the issue form template, and join them with the preceding, valid field.
BTW I love the idea of using issue forms to generate blog posts. If you ever decide to open source that project, I'd love to share it! I'm working on some documentation around IssueOps, and it would make a cool use case :)
Given the following template:
and the following example Issue:
the parsed JSON looks like
we can see it's
link
fieldheader_3
field instead of preserving it inside ofcontent
That is, the expected output should be:
The text was updated successfully, but these errors were encountered: