Skip to content

Commit 6cfd00c

Browse files
authored
fix: Do not convert ids to dashes in output (#19)
BREAKING CHANGE: Before this change, IDs defined in a GitHub issue template that included a hyphen got converted to dashes for the Action output. This was mainly done to ensure nice-looking output variables. However, this is confusing as discussed in #15 (comment).
1 parent 21b7212 commit 6cfd00c

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,6 @@ jobs:
2323
git config user.email github-actions@github.com
2424
git add .gitignore dist/
2525
git commit -m "build"
26-
git push --force https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git HEAD:refs/heads/v1
26+
git push --force https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git HEAD:refs/heads/v2
2727
env:
2828
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Use this action to convert issues into a unified JSON structure.
55
## Setup
66

77
```yml
8-
- uses: stefanbuck/github-issue-parser@v1
8+
- uses: stefanbuck/github-issue-parser@v2
99
id: issue-parser
1010
with:
1111
template-path: .github/ISSUE_TEMPLATE/bug-report.yml
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
2-
"textarea_one": "1st paragraph\n\n2nd paragraph",
3-
"textarea_two": "1st paragraph\n2nd paragraph"
4-
}
2+
"textarea-one": "1st paragraph\n\n2nd paragraph",
3+
"textarea-two": "1st paragraph\n2nd paragraph"
4+
}

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ async function run(env, eventPayload, fs, core) {
4444

4545
function toKey(str) {
4646
if (idMapping[str]) {
47-
return idMapping[str].replace(/-/g, "_");
47+
return idMapping[str];
4848
}
4949

5050
return str

0 commit comments

Comments
 (0)