Skip to content

Add a --revert/--restore flag, --apply counterpart#431

Merged
bl-ue merged 2 commits intomainfrom
add-restore-flag
Jan 29, 2026
Merged

Add a --revert/--restore flag, --apply counterpart#431
bl-ue merged 2 commits intomainfrom
add-restore-flag

Conversation

@bl-ue
Copy link
Copy Markdown
Member

@bl-ue bl-ue commented Jan 29, 2026

Summary by CodeRabbit

  • New Features

    • Added restore/revert commands to undo previous changes and restore the original installation.
    • Non-interactive restore flow provides discovery, restoration steps, and post-restore guidance.
  • Improvements

    • Enhanced apply flow with colored success messages and clearer guidance on reverting.
    • Validation prevents conflicting operations; improved error handling and user-facing messages.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Jan 29, 2026

Caution

Review failed

The pull request is closed.

📝 Walkthrough
🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: adding --revert/--restore flags as counterparts to --apply, which aligns with the primary objective of implementing a restore/revert functionality.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@src/index.tsx`:
- Around line 182-201: The restore flow can throw when a backup file is missing
so the friendly "No backup found" message never appears; update the restore
logic to treat missing-file errors as "not restored" by wrapping the calls to
restoreClijsFromBackup and restoreNativeBinaryFromBackup in try/catch (or add an
fs.exists check inside those helpers) and if an error with code 'ENOENT' occurs,
set restored = false (rather than letting the exception escape); keep other
errors propagated/logged as before and ensure the restored boolean is used
unmodified for the existing error messages and process.exit(1) behavior.

@bl-ue bl-ue enabled auto-merge (squash) January 29, 2026 04:20
@bl-ue bl-ue merged commit a87b152 into main Jan 29, 2026
1 of 2 checks passed
@bl-ue bl-ue deleted the add-restore-flag branch January 29, 2026 04:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant