Skip to content

Refactor cloud-agent cli entry point#27

Merged
jxnl merged 1 commit into
mainfrom
cursor/refactor-cloud-agent-cli-entry-point-abaf
Nov 24, 2025
Merged

Refactor cloud-agent cli entry point#27
jxnl merged 1 commit into
mainfrom
cursor/refactor-cloud-agent-cli-entry-point-abaf

Conversation

@jxnl

@jxnl jxnl commented Nov 24, 2025

Copy link
Copy Markdown
Collaborator

Refactor the cloud-agent.tsx CLI entry point to improve code quality, maintainability, and error handling.


Open in Cursor Open in Web


Important

Refactor cloud-agent.tsx to improve code structure, error handling, and command registration logic.

  • Functions:
    • Introduced printApiKeyError() for consistent API key error messaging.
    • Added createProgram() to encapsulate Command creation and registration.
    • Added showInteractiveMenu() to handle interactive menu rendering.
  • Error Handling:
    • Enhanced error handling in main() to log stack trace if DEBUG is set.
    • Improved error message for missing CURSOR_API_KEY.
  • Command Registration:
    • Refactored command registration to use createProgram() for both help and execution contexts.
    • Simplified command detection logic in main() using program.commands.some().
  • Misc:
    • Removed redundant command registration logic.
    • Updated version retrieval from package.json.

This description was created by Ellipsis for d34a680. You can customize this summary. It will automatically update as commits are pushed.

Co-authored-by: jason <jason@jxnl.co>
@cursor

cursor Bot commented Nov 24, 2025

Copy link
Copy Markdown

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@jxnl jxnl marked this pull request as ready for review November 24, 2025 19:57
@jxnl jxnl merged commit a7a3e5a into main Nov 24, 2025
0 of 2 checks passed
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.

2 participants