From d70e077c5631b4cf89f5e3b49401d9060785ba6e Mon Sep 17 00:00:00 2001 From: Sisyphus Date: Thu, 25 Dec 2025 13:29:34 +0900 Subject: [PATCH] fix: preserve backticks in Sisyphus GitHub comments (#203) --- .github/workflows/sisyphus-agent.yml | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sisyphus-agent.yml b/.github/workflows/sisyphus-agent.yml index e87142b..aab883f 100644 --- a/.github/workflows/sisyphus-agent.yml +++ b/.github/workflows/sisyphus-agent.yml @@ -149,8 +149,32 @@ jobs: User CANNOT see console. Post everything via `gh issue comment` or `gh pr comment`. + ### Comment Formatting (CRITICAL) + + **ALWAYS use heredoc syntax for comments containing code references, backticks, or multiline content:** + + ```bash + gh issue comment --body "$(cat <<'EOF' + Your comment with `backticks` and code references preserved here. + Multiple lines work perfectly. + EOF + )" + ``` + + **NEVER use direct quotes with backticks** (shell will interpret them as command substitution): + ```bash + # WRONG - backticks disappear: + gh issue comment 123 --body "text with `code`" + + # CORRECT - backticks preserved: + gh issue comment 123 --body "$(cat <<'EOF' + text with `code` + EOF + )" + ``` + ### Rules - - EVERY response = GitHub comment + - EVERY response = GitHub comment (use heredoc for proper escaping) - Code changes = PR (never push main/master) - Setup: bun install first - Acknowledge immediately, report when done