Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 9 additions & 43 deletions .claude/commands/release.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
---
description: "Create a new release: bump version, create PR, build mainnet, publish draft release"
argument_hint: "[--critical]"
allowed_tools: Bash, Read, Edit, Write, Glob, Grep, AskUserQuestion, mcp__github__create_pull_request, mcp__github__list_pull_requests, mcp__github__pull_request_read, mcp__github__get_file_contents, mcp__github__update_pull_request
---

Automate the full release process for bitkit-android.

**Examples:**
- `/release` - Interactive, prompts for version (defaults to patch bump)
- `/release --critical` - Same, but marks the release as critical in release.json

## Steps

Expand All @@ -26,12 +24,7 @@ Compute defaults:
- Next major: `{major+1}.0.0`
- Next versionCode: `versionCode + 1`

### 2. Parse Arguments

From `$ARGUMENTS`:
- `--critical`: Set `critical: true` in `.github/release.json` (default: `false`)

### 3. Ask for Version
### 2. Ask for Version

Use `AskUserQuestion` with header "Version":

Expand All @@ -46,7 +39,7 @@ The user can always pick "Other" to enter a custom version string.

Store the chosen version as `newVersionName` and compute `newVersionCode = versionCode + 1`.

### 4. Create Release Branch & Bump Version
### 3. Create Release Branch & Bump Version

```bash
git checkout master
Expand All @@ -64,7 +57,7 @@ git commit -m "chore: version {newVersionName}"
git push -u origin release/{newVersionCode}
```

### 5. Create Version Bump PR
### 4. Create Version Bump PR

Read `.github/pull_request_template.md` for structure. Create PR:

Expand All @@ -90,7 +83,7 @@ N/A

Store the PR URL for the summary.

### 6. Build Mainnet Release
### 5. Build Mainnet Release

```bash
./gradlew assembleMainnetRelease
Expand All @@ -100,34 +93,7 @@ Expected APK path: `app/build/outputs/apk/mainnet/release/bitkit-mainnet-release

Verify the file exists. If the build fails, stop and report the error to the user.

### 7. Update `.github/release.json`

Get current UTC timestamp: `date -u +"%Y-%m-%dT%H:%M:%SZ"`

Write `.github/release.json`:
```json
{
"platforms": {
"android": {
"version": "v{newVersionName}",
"buildNumber": {newVersionCode},
"notes": "https://github.com/synonymdev/bitkit/releases/tag/v{newVersionName}",
"pub_date": "{UTC timestamp}",
"url": "https://play.google.com/store/apps/details?id=to.bitkit",
"critical": {true if --critical flag, false otherwise}
}
}
}
```

Commit and push:
```bash
git add .github/release.json
git commit -m "chore: update release.json"
git push
```

### 8. Tag & Push
### 6. Tag & Push

Determine the previous version tag for changelog generation: `v{oldVersionName}`.

Expand All @@ -136,7 +102,7 @@ git tag -a v{newVersionName} -m "v{newVersionName}"
git push origin v{newVersionName}
```

### 9. Create Draft GitHub Release
### 7. Create Draft GitHub Release

```bash
gh release create v{newVersionName} \
Expand All @@ -146,20 +112,20 @@ gh release create v{newVersionName} \
--notes-start-tag v{oldVersionName}
```

### 10. Upload APK to Draft Release
### 8. Upload APK to Draft Release

```bash
gh release upload v{newVersionName} \
app/build/outputs/apk/mainnet/release/bitkit-mainnet-release-{newVersionCode}-universal.apk
```

### 11. Return to Master
### 9. Return to Master

```bash
git checkout master
```

### 12. Output Summary
### 10. Output Summary

```
Release v{newVersionName} (build {newVersionCode})
Expand Down
13 changes: 0 additions & 13 deletions .github/release.json

This file was deleted.

11 changes: 6 additions & 5 deletions .github/workflows/claude-code-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ on:
# - "src/**/*.js"
# - "src/**/*.jsx"

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}
cancel-in-progress: true

jobs:
claude-review:
# Optional: Filter by PR author
Expand Down Expand Up @@ -56,11 +60,8 @@ jobs:
uses: anthropics/claude-code-action@v1
with:
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
# use_sticky_comment: "true" # doesn't work
plugin_marketplaces: 'https://github.com/anthropics/claude-code.git'
plugins: 'code-review@claude-code-plugins'
prompt: '/code-review:code-review ${{ github.repository }}/pull/${{ github.event.pull_request.number }}'
# Allow Claude bot to trigger this workflow
allowed_bots: 'claude[bot]'
# Allow Claude to use GH CLI for reading external PR details and fetch web content
claude_args: '--allowed-tools Bash(gh:*) WebFetch'
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
# or https://code.claude.com/docs/en/cli-reference for available options
1 change: 0 additions & 1 deletion .github/workflows/claude.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ jobs:
uses: anthropics/claude-code-action@v1
with:
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
use_api_for_commits: true

# This is an optional setting that allows Claude to read CI results on PRs
additional_permissions: |
Expand Down
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ ktor-client-core = { module = "io.ktor:ktor-client-core", version.ref = "ktor" }
ktor-client-logging = { module = "io.ktor:ktor-client-logging", version.ref = "ktor" }
ktor-client-okhttp = { module = "io.ktor:ktor-client-okhttp", version.ref = "ktor" }
ktor-serialization-kotlinx-json = { module = "io.ktor:ktor-serialization-kotlinx-json", version.ref = "ktor" }
ldk-node-android = { module = "com.synonym:ldk-node-android", version = "0.7.0-rc.29" }
ldk-node-android = { module = "com.synonym:ldk-node-android", version = "0.7.0-rc.31" }
lifecycle-process = { group = "androidx.lifecycle", name = "lifecycle-process", version.ref = "lifecycle" }
lifecycle-runtime-compose = { module = "androidx.lifecycle:lifecycle-runtime-compose", version.ref = "lifecycle" }
lifecycle-runtime-ktx = { module = "androidx.lifecycle:lifecycle-runtime-ktx", version.ref = "lifecycle" }
Expand Down
Loading