Skip to content
This repository was archived by the owner on Sep 5, 2025. It is now read-only.

Commit 5344bb6

Browse files
paul-fractureclaude
andcommitted
Fix multi-line feedback handling by removing newlines
- Added newline removal in all user feedback handling - Processing feedback with 'tr' to convert newlines to spaces - Simplifies output handling in GitHub Actions - Bumped version to 0.5.6 for the fix - Updated all version references throughout the codebase This fixes the issue with multi-line comments causing GitHub Actions output parsing errors. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent 66dd276 commit 5344bb6

File tree

4 files changed

+25
-13
lines changed

4 files changed

+25
-13
lines changed

.github/workflows/claude-full.yml

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,10 @@ jobs:
4949
FEEDBACK="${{ github.event.comment.body }}"
5050
# Remove the "claude:" prefix
5151
FEEDBACK="${FEEDBACK#claude:}"
52+
# Remove newlines from feedback to prevent GitHub Actions output issues
53+
FEEDBACK_CLEANED="$(echo "$FEEDBACK" | tr '\n' ' ')"
5254
echo "number=${ISSUE_NUMBER}" >> $GITHUB_OUTPUT
53-
echo "feedback=${FEEDBACK}" >> $GITHUB_OUTPUT
55+
echo "feedback=${FEEDBACK_CLEANED}" >> $GITHUB_OUTPUT
5456
5557
- name: Process with Claude Code for issue analysis
5658
uses: fractureinc/[email protected]
@@ -102,8 +104,10 @@ jobs:
102104
FEEDBACK="${{ github.event.comment.body }}"
103105
# Remove the "claude-fix:" prefix
104106
FEEDBACK="${FEEDBACK#claude-fix:}"
107+
# Remove newlines from feedback to prevent GitHub Actions output issues
108+
FEEDBACK_CLEANED="$(echo "$FEEDBACK" | tr '\n' ' ')"
105109
echo "number=${ISSUE_NUMBER}" >> $GITHUB_OUTPUT
106-
echo "feedback=${FEEDBACK}" >> $GITHUB_OUTPUT
110+
echo "feedback=${FEEDBACK_CLEANED}" >> $GITHUB_OUTPUT
107111
108112
- name: Process with Claude Code for issue fix
109113
uses: fractureinc/[email protected]
@@ -147,8 +151,10 @@ jobs:
147151
FEEDBACK="${{ github.event.comment.body }}"
148152
# Remove the "claude:" prefix
149153
FEEDBACK="${FEEDBACK#claude:}"
154+
# Remove newlines from feedback to prevent GitHub Actions output issues
155+
FEEDBACK_CLEANED="$(echo "$FEEDBACK" | tr '\n' ' ')"
150156
echo "number=${PR_NUMBER}" >> $GITHUB_OUTPUT
151-
echo "feedback=${FEEDBACK}" >> $GITHUB_OUTPUT
157+
echo "feedback=${FEEDBACK_CLEANED}" >> $GITHUB_OUTPUT
152158
153159
- name: Process with Claude Code
154160
uses: fractureinc/[email protected]
@@ -180,8 +186,10 @@ jobs:
180186
FEEDBACK="${{ github.event.comment.body }}"
181187
# Remove the "claude-suggest:" prefix
182188
FEEDBACK="${FEEDBACK#claude-suggest:}"
189+
# Remove newlines from feedback to prevent GitHub Actions output issues
190+
FEEDBACK_CLEANED="$(echo "$FEEDBACK" | tr '\n' ' ')"
183191
echo "number=${PR_NUMBER}" >> $GITHUB_OUTPUT
184-
echo "feedback=${FEEDBACK}" >> $GITHUB_OUTPUT
192+
echo "feedback=${FEEDBACK_CLEANED}" >> $GITHUB_OUTPUT
185193
186194
- name: Process with Claude Code Suggestions
187195
uses: fractureinc/[email protected]
@@ -219,8 +227,10 @@ jobs:
219227
FILE_PATH="${{ github.event.comment.path }}"
220228
LINE="${{ github.event.comment.line }}"
221229
230+
# Remove newlines from feedback to prevent GitHub Actions output issues
231+
FEEDBACK_CLEANED="$(echo "$FEEDBACK" | tr '\n' ' ')"
222232
echo "number=${PR_NUMBER}" >> $GITHUB_OUTPUT
223-
echo "feedback=${FEEDBACK}" >> $GITHUB_OUTPUT
233+
echo "feedback=${FEEDBACK_CLEANED}" >> $GITHUB_OUTPUT
224234
225235
echo "comment_id=${COMMENT_ID}" >> $GITHUB_OUTPUT
226236
echo "file_path=${FILE_PATH}" >> $GITHUB_OUTPUT
@@ -260,8 +270,10 @@ jobs:
260270
FILE_PATH="${{ github.event.comment.path }}"
261271
LINE="${{ github.event.comment.line }}"
262272
273+
# Remove newlines from feedback to prevent GitHub Actions output issues
274+
FEEDBACK_CLEANED="$(echo "$FEEDBACK" | tr '\n' ' ')"
263275
echo "number=${PR_NUMBER}" >> $GITHUB_OUTPUT
264-
echo "feedback=${FEEDBACK}" >> $GITHUB_OUTPUT
276+
echo "feedback=${FEEDBACK_CLEANED}" >> $GITHUB_OUTPUT
265277
266278
echo "comment_id=${COMMENT_ID}" >> $GITHUB_OUTPUT
267279
echo "file_path=${FILE_PATH}" >> $GITHUB_OUTPUT

.github/workflows/example-minimal.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
# This demonstrates how to use the reusable workflow for comment-based interactions
1010
jobs:
1111
claude-integration:
12-
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].5
12+
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].6
1313
with:
1414
# Optional customizations:
1515
issue-label: 'claude-fix' # The label used to trigger issue fixes

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ on:
3030

3131
jobs:
3232
claude-integration:
33-
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].5
33+
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].6
3434
with:
3535
issue-label: 'claude-fix' # Optional: customize the trigger label
3636
secrets:
@@ -47,7 +47,7 @@ on:
4747
4848
jobs:
4949
claude-label-fix:
50-
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].5
50+
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].6
5151
with:
5252
issue-label: 'claude-fix' # Must match your chosen label
5353
secrets:
@@ -97,7 +97,7 @@ The reusable workflows support several configuration options:
9797
```yaml
9898
jobs:
9999
claude-integration:
100-
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].5
100+
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].6
101101
with:
102102
# All parameters are optional with sensible defaults
103103
issue-label: 'claude-fix' # Label that triggers issue fixes
@@ -113,7 +113,7 @@ jobs:
113113
```yaml
114114
jobs:
115115
claude-label-fix:
116-
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].5
116+
uses: fractureinc/claude-code-github-action/.github/workflows/[email protected].6
117117
with:
118118
# All parameters are optional with sensible defaults
119119
issue-label: 'claude-fix' # Must match the label you're using
@@ -152,7 +152,7 @@ All parameters are optional and have sensible defaults.
152152

153153
## Enhanced Context for Claude
154154

155-
With version 0.5.5, Claude now receives complete context for your PRs and issues, including:
155+
With version 0.5.6, Claude now receives complete context for your PRs and issues, including:
156156

157157
- PR metadata (title, description, branch info)
158158
- Issue details (title, description, labels)

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "claude-code-github-action",
3-
"version": "0.5.5",
3+
"version": "0.5.6",
44
"description": "GitHub action for Claude Code Integration in PR comments, reviews, inline code suggestions, and issue-based fixes",
55
"main": "index.js",
66
"scripts": {

0 commit comments

Comments
 (0)