Skip to content

Commit 9971291

Browse files
committed
docs: update CHANGELOG and README for Phase 3 features
Add documentation for new rebase features: - Progress reporting during chain rebase - Summary report after rebase completion - --status flag for viewing in-progress rebase state - --cleanup-backups flag for deleting backup branches - New integration tests Update README with flag descriptions, usage examples, and a new "Progress Reporting and Summary" section with sample output.
1 parent cb402cb commit 9971291

2 files changed

Lines changed: 66 additions & 0 deletions

File tree

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
88
## [Unreleased]
99

1010
### Changed
11+
- Rebase now shows progress reporting during chain rebase: `📌 [2/5] Rebasing feature-auth onto main...`
12+
- Rebase completion now shows a summary report with counts by category (rebased, skipped, squash-reset)
13+
- `rebase --continue` and `rebase --skip` now show progress reporting and summary report
1114
- Rebase conflict error message now shows numbered recovery steps with `--continue` and `--abort` instructions
1215
- Replaced `process::exit(1)` with proper error propagation in core operations
1316
- `rebase`, `backup`, `push`, `prune`, and `pr` operations now return `Result<(), Error>` instead of calling `process::exit(1)`
@@ -62,6 +65,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
6265
- `rebase_squashed_merge_skip`, `rebase_squashed_merge_force_rebase`
6366
- Added `lint` Makefile target (combines `fmt-check` + `clippy-strict`)
6467
- Added `test-file` Makefile target for running all tests in a specific file
68+
- Added `--status` flag to `rebase` command to show current chain rebase state
69+
- Displays per-branch status with emoji indicators (Completed, Skipped, Pending, Conflict, etc.)
70+
- Shows progress through the chain and original branch information
71+
- Reports "No chain rebase in progress" when no state file exists
72+
- Added `--cleanup-backups` flag to `rebase` command for deleting backup branches after successful rebase
73+
- Works with `rebase`, `rebase --continue`, and `rebase --skip`
74+
- Deletes `backup-<chain>/<branch>` branches created during squash-merge reset
75+
- Reports count of cleaned up backup branches
76+
- Added integration tests for Phase 3 polish and UX features:
77+
- `rebase_progress_reporting`, `rebase_status_no_state`, `rebase_status_during_conflict`
78+
- `rebase_cleanup_backups`, `rebase_no_cleanup_without_flag`, `rebase_summary_report_with_skipped_branches`
6579
- Added integration tests for error propagation:
6680
- `rebase_nonexistent_chain`, `rebase_dirty_working_directory`, `rebase_missing_branch_in_chain`
6781
- `backup_nonexistent_chain`, `push_nonexistent_chain`, `prune_nonexistent_chain`

README.md

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,18 @@ Git Chain's rebase command offers customization through its flags:
118118
```
119119
Rolls back the entire chain rebase by restoring all branches to their original positions before the rebase started. Aborts any in-progress git rebase and cleans up the state file.
120120

121+
- **`--status`**: Show the current chain rebase state
122+
```
123+
git chain rebase --status
124+
```
125+
Displays the status of each branch in an ongoing chain rebase, including which branches have been completed, skipped, or are still pending. Reports "No chain rebase in progress" when no state file exists.
126+
127+
- **`--cleanup-backups`**: Delete backup branches after successful rebase
128+
```
129+
git chain rebase --cleanup-backups
130+
```
131+
After a successful rebase, automatically deletes any `backup-<chain>/<branch>` branches that were created during squash-merge reset. Can also be combined with `--continue` and `--skip`.
132+
121133
- **`--squashed-merge=<mode>`**: How to handle branches detected as squash-merged
122134
```
123135
git chain rebase --squashed-merge=reset # Default: auto-backup + reset to parent
@@ -260,6 +272,40 @@ Rebasing branch feature/profiles onto feature/auth...
260272
# Continues with remaining branches
261273
```
262274

275+
### Progress Reporting and Summary
276+
277+
When rebasing a chain, git-chain provides real-time progress and a summary report:
278+
279+
**During rebase**:
280+
```
281+
📌 [1/3] Rebasing feature-auth onto master...
282+
📌 [2/3] Rebasing feature-profiles onto feature-auth...
283+
📌 [3/3] Rebasing feature-settings onto feature-profiles...
284+
```
285+
286+
**After completion**:
287+
```
288+
📊 Rebase Summary for Chain: my-feature
289+
✅ Rebased: 3
290+
291+
🎉 Successfully rebased chain my-feature
292+
```
293+
294+
**Checking rebase status** during a conflict:
295+
```
296+
$ git chain rebase --status
297+
298+
📊 Chain Rebase Status: my-feature
299+
Root: master
300+
301+
✅ feature-auth (1/3) onto master — Completed
302+
❌ feature-profiles (2/3) onto feature-auth — Conflict ← current
303+
⏳ feature-settings (3/3) onto feature-profiles — Pending
304+
305+
Progress: 1/3 branches completed
306+
Original branch: feature-settings
307+
```
308+
263309
### Recovery Options
264310

265311
If a rebase goes wrong, Git Chain provides several recovery options:
@@ -677,6 +723,12 @@ git chain rebase --step
677723
# Skip rebasing the first branch onto the root branch
678724
git chain rebase --ignore-root
679725
726+
# Show the status of an in-progress chain rebase
727+
git chain rebase --status
728+
729+
# Delete backup branches after successful rebase
730+
git chain rebase --cleanup-backups
731+
680732
# Specify how to handle squash-merged branches during rebase
681733
git chain rebase --squashed-merge=reset # Auto-backup + reset (default)
682734
git chain rebase --squashed-merge=skip # Skip squash-merged branches

0 commit comments

Comments
 (0)