Skip to content

Commit b51c6f7

Browse files
authored
Merge pull request #12 from lroolle/feat/ci-release
feat: clean startup message redesign and CI/CD setup
2 parents 45d8f6a + 42ffba1 commit b51c6f7

7 files changed

Lines changed: 505 additions & 122 deletions

File tree

.github/ISSUE_TEMPLATE.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
## Description
2+
Brief description of the issue or feature request.
3+
4+
## Type
5+
- [ ] Bug fix
6+
- [ ] New feature
7+
- [ ] Enhancement
8+
- [ ] Documentation
9+
10+
## Details
11+
Detailed description of the problem and proposed solution.
12+
13+
## Related Files
14+
List of files that need to be modified.
15+
16+
## Test Plan
17+
How to verify the fix works.

.github/workflows/release.yml

Lines changed: 146 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,146 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- "v*"
7+
workflow_dispatch:
8+
inputs:
9+
tag:
10+
description: "Tag to release"
11+
required: true
12+
type: string
13+
14+
env:
15+
REGISTRY: ghcr.io
16+
IMAGE_NAME: ${{ github.repository }}
17+
18+
jobs:
19+
shellcheck:
20+
name: Shell Linting
21+
runs-on: ubuntu-latest
22+
steps:
23+
- name: Checkout
24+
uses: actions/checkout@v4
25+
26+
- name: Run ShellCheck
27+
uses: ludeeus/action-shellcheck@master
28+
with:
29+
scandir: "."
30+
format: gcc
31+
severity: warning
32+
33+
build-and-push:
34+
name: Build and Push Docker Image
35+
runs-on: ubuntu-latest
36+
needs: shellcheck
37+
permissions:
38+
contents: read
39+
packages: write
40+
steps:
41+
- name: Checkout
42+
uses: actions/checkout@v4
43+
44+
- name: Set up QEMU
45+
uses: docker/setup-qemu-action@v3
46+
47+
- name: Set up Docker Buildx
48+
uses: docker/setup-buildx-action@v3
49+
50+
- name: Log in to Container Registry
51+
uses: docker/login-action@v3
52+
with:
53+
registry: ${{ env.REGISTRY }}
54+
username: ${{ github.actor }}
55+
password: ${{ secrets.GITHUB_TOKEN }}
56+
57+
- name: Extract metadata
58+
id: meta
59+
uses: docker/metadata-action@v5
60+
with:
61+
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
62+
tags: |
63+
type=ref,event=tag
64+
type=raw,value=latest,enable={{is_default_branch}}
65+
66+
- name: Build and push Docker image
67+
uses: docker/build-push-action@v5
68+
with:
69+
context: .
70+
platforms: linux/amd64,linux/arm64
71+
push: true
72+
tags: ${{ steps.meta.outputs.tags }}
73+
labels: ${{ steps.meta.outputs.labels }}
74+
cache-from: type=gha
75+
cache-to: type=gha,mode=max
76+
77+
release:
78+
name: Create GitHub Release
79+
runs-on: ubuntu-latest
80+
needs: build-and-push
81+
permissions:
82+
contents: write
83+
steps:
84+
- name: Checkout
85+
uses: actions/checkout@v4
86+
with:
87+
fetch-depth: 0
88+
89+
- name: Get version from tag
90+
id: version
91+
run: |
92+
if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then
93+
echo "version=${{ github.event.inputs.tag }}" >> $GITHUB_OUTPUT
94+
else
95+
echo "version=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
96+
fi
97+
98+
- name: Update version in claude.sh
99+
run: |
100+
VERSION="${{ steps.version.outputs.version }}"
101+
# Remove 'v' prefix if present
102+
VERSION=${VERSION#v}
103+
sed -i "s/^VERSION=.*/VERSION=\"$VERSION\"/" claude.sh
104+
git config --local user.email "action@github.com"
105+
git config --local user.name "GitHub Action"
106+
git add claude.sh
107+
git commit -m "Update version to $VERSION" || echo "No changes to commit"
108+
109+
- name: Generate release notes
110+
id: release_notes
111+
run: |
112+
# Get the previous tag
113+
PREVIOUS_TAG=$(git describe --tags --abbrev=0 HEAD~1 2>/dev/null || echo "")
114+
115+
# Generate release notes
116+
if [ -n "$PREVIOUS_TAG" ]; then
117+
echo "## Changes since $PREVIOUS_TAG" > release_notes.md
118+
echo "" >> release_notes.md
119+
git log --pretty=format:"- %s (%h)" $PREVIOUS_TAG..HEAD >> release_notes.md
120+
else
121+
echo "## Initial Release" > release_notes.md
122+
echo "" >> release_notes.md
123+
echo "First release of Claude Code YOLO - Docker wrapper for Claude CLI with safe YOLO mode." >> release_notes.md
124+
fi
125+
126+
echo "" >> release_notes.md
127+
echo "## Docker Images" >> release_notes.md
128+
echo "" >> release_notes.md
129+
echo "- \`ghcr.io/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.version }}\`" >> release_notes.md
130+
echo "- \`ghcr.io/${{ env.IMAGE_NAME }}:latest\`" >> release_notes.md
131+
echo "" >> release_notes.md
132+
echo "## Supported Architectures" >> release_notes.md
133+
echo "" >> release_notes.md
134+
echo "- linux/amd64" >> release_notes.md
135+
echo "- linux/arm64" >> release_notes.md
136+
137+
- name: Create Release
138+
uses: softprops/action-gh-release@v1
139+
with:
140+
tag_name: ${{ steps.version.outputs.version }}
141+
name: Release ${{ steps.version.outputs.version }}
142+
body_path: release_notes.md
143+
generate_release_notes: true
144+
append_body: true
145+
env:
146+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

CHANGELOG.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
### Added
11+
- Unified logging system for improved UX
12+
- Clean output by default showing only authentication method
13+
- Verbose mode displays model selection, proxy configuration, and debug info
14+
1015
### Fixed
1116
- Argument parsing infinite loop in claude-yolo for --inspect and --ps options
1217
- Duplicate argument handling causing inconsistent behavior with mixed options
@@ -16,6 +21,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1621
### Changed
1722
- Consolidated all claude-yolo argument parsing through single parse_args() function
1823
- Enhanced claude-trace argument injection for proper --dangerously-skip-permissions placement
24+
- Improved logging organization
25+
- Updated documentation with logging capabilities and examples
1926

2027
## [0.1.0] - 2025-06-21
2128

@@ -51,4 +58,4 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
5158
- Directory access limited to current working directory
5259
- Non-root execution inside container
5360
- Docker socket mounting disabled by default
54-
- Warning system for dangerous directories (home, system directories)
61+
- Warning system for dangerous directories (home, system directories)

CLAUDE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ npm install -g @mariozechner/claude-trace
129129
# Enable tracing in local mode
130130
./claude.sh --trace .
131131

132-
# Enable tracing in YOLO mode
132+
# Enable tracing in YOLO mode
133133
./claude.sh --yolo --trace .
134134

135135
# Bedrock with tracing

0 commit comments

Comments
 (0)