mirror of
https://github.com/xtr-dev/payload-mailing.git
synced 2025-12-10 00:03:23 +00:00
Update Claude CLI command to use correct syntax with print mode
### 🐛 Bug Fixes - Changed from `claude-code` to `claude -p` for non-interactive execution - Fixed YAML syntax issues with multiline command arguments - Used separate PROMPT variable to avoid YAML parsing conflicts ### 🔧 Improvements - Uses correct Claude CLI syntax with -p/--print flag for automation - Properly structured command for GitHub Actions environment - Maintains changelog generation functionality with correct CLI invocation 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
11
.github/workflows/version-and-publish.yml
vendored
11
.github/workflows/version-and-publish.yml
vendored
@@ -114,14 +114,13 @@ jobs:
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Generate changelog using Claude (fail if it fails)
|
# Generate changelog using Claude (fail if it fails)
|
||||||
if ! command -v claude-code >/dev/null 2>&1; then
|
if ! command -v claude >/dev/null 2>&1; then
|
||||||
echo "❌ ERROR: Claude CLI installation failed."
|
echo "❌ ERROR: Claude CLI installation failed."
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "🤖 Generating changelog with Claude..."
|
echo "🤖 Generating changelog with Claude..."
|
||||||
CHANGELOG=$(timeout 240s claude-code << 'CLAUDE_EOF'
|
PROMPT="Please analyze the following git commits and generate a concise changelog in this exact format:
|
||||||
Please analyze the following git commits and generate a concise changelog in this exact format:
|
|
||||||
|
|
||||||
## Changes
|
## Changes
|
||||||
|
|
||||||
@@ -143,9 +142,9 @@ jobs:
|
|||||||
Only include sections that have actual changes. Keep each bullet point concise and user-focused.
|
Only include sections that have actual changes. Keep each bullet point concise and user-focused.
|
||||||
|
|
||||||
Git commits to analyze:
|
Git commits to analyze:
|
||||||
$COMMITS
|
$COMMITS"
|
||||||
CLAUDE_EOF
|
|
||||||
)
|
CHANGELOG=$(timeout 240s claude -p "$PROMPT")
|
||||||
|
|
||||||
# Check if changelog generation succeeded
|
# Check if changelog generation succeeded
|
||||||
if [ $? -ne 0 ] || [ -z "$CHANGELOG" ]; then
|
if [ $? -ne 0 ] || [ -z "$CHANGELOG" ]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user