Skip to content

Conversation

@devin-ai-integration
Copy link
Contributor

Remove deprecated and redundant CLI commands

Summary

This PR removes 13 CLI commands that were identified as deprecated, redundant, poorly documented, or experimental. The cleanup removes ~4,900 lines of code while preserving all core CLI functionality.

Commands removed:

  • runtasks - deprecated in favor of configure
  • recreate - redundant with delete + start sequence
  • hello - onboarding command with references across multiple commands
  • background - niche use case with limited documentation
  • test, clipboard, envvars, connect, fu - dev-only commands behind feature flags
  • writeconnectionevent, updatemodel - poorly documented internal commands
  • configure-env-vars, import-ide-config, secret - user-specified removals
  • Fixed duplicate start command registration

Core commands preserved: start, stop, delete, reset, login, logout, ls, shell, open, create, org, set, etc.

Review & Testing Checklist for Human

  • Verify removed commands aren't used in production - Check internal scripts, documentation, CI/CD, or user-facing materials that might reference these commands
  • Test new user onboarding flow - The hello command and onboarding logic was completely removed from login, ls, shell, and open commands. Ensure new users can still successfully get started
  • End-to-end testing of core workflows - Test primary user journeys: login → ls → start → shell/open to ensure nothing is broken
  • Check for references in other repos - Search for usage of removed commands in related repositories or documentation sites

Diagram

%%{ init : { "theme" : "default" }}%%
graph TD
    cmd["pkg/cmd/cmd.go<br/>Command Registration"]:::major-edit
    
    login["pkg/cmd/login/login.go<br/>Login Command"]:::minor-edit
    shell["pkg/cmd/shell/shell.go<br/>Shell Command"]:::minor-edit
    ollama["pkg/cmd/ollama/ollama.go<br/>Ollama Command"]:::minor-edit
    notebook["pkg/cmd/notebook/notebook.go<br/>Notebook Command"]:::minor-edit
    open["pkg/cmd/open/open.go<br/>Open Command"]:::minor-edit
    ls["pkg/cmd/ls/ls.go<br/>List Command"]:::minor-edit
    
    hello["pkg/cmd/hello/<br/>(DELETED)"]:::deleted
    runtasks["pkg/cmd/runtasks/<br/>(DELETED)"]:::deleted
    recreate["pkg/cmd/recreate/<br/>(DELETED)"]:::deleted
    others["11 other command dirs<br/>(DELETED)"]:::deleted
    
    cmd --> login
    cmd --> shell
    cmd --> ollama
    cmd --> notebook
    cmd --> open
    cmd --> ls
    
    cmd -.-> hello
    cmd -.-> runtasks  
    cmd -.-> recreate
    cmd -.-> others
    
    hello -.-> login
    hello -.-> shell
    hello -.-> open
    hello -.-> ls
    
    subgraph Legend
        L1[Major Edit]:::major-edit
        L2[Minor Edit]:::minor-edit
        L3[Deleted]:::deleted
    end
    
    classDef major-edit fill:#90EE90
    classDef minor-edit fill:#87CEEB  
    classDef deleted fill:#FFB6C1
Loading

Notes

  • Build verified: CLI compiles successfully and core commands show expected help output
  • Import cleanup: Removed unused imports and resolved all compilation errors
  • UX changes: Replaced TypeItToMeUnskippable27 calls with simple terminal prints - behavior may differ slightly
  • Session info: Requested by Alec Fong (@theFong) - Devin session

- Remove deprecated runtasks command (replaced by configure)
- Remove redundant recreate command (equivalent to delete + start)
- Remove dev-only commands: test, clipboard, envvars, connect, fu
- Remove poorly documented commands: writeconnectionevent, updatemodel
- Remove user-specified commands: configure-env-vars, import-ide-config, secret
- Remove hello onboarding command and references
- Fix duplicate start command registration

This cleanup improves CLI organization and removes unused/experimental functionality.
All core commands (start, stop, delete, reset, login, logout, ls, shell, open) remain intact.

Co-Authored-By: Alec Fong <[email protected]>
@devin-ai-integration
Copy link
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

devin-ai-integration bot and others added 5 commits July 20, 2025 01:03
The funlen nolint directive is no longer needed after removing
deprecated commands from createCmdTree function.

Also fix gofumpt formatting in notebook.go.

Co-Authored-By: Alec Fong <[email protected]>
- Remove ollama import and registration from cmd.go
- Delete pkg/cmd/ollama directory and all related files
- Ollama command was identified as an additional removal request

This completes the CLI command cleanup by removing the AI/ML
model server functionality from the core CLI.

Co-Authored-By: Alec Fong <[email protected]>
- Remove status import and registration from cmd.go
- Delete pkg/cmd/status directory and all related files
- Status command was identified as an additional removal request

This further streamlines the CLI by removing the instance status
functionality that was redundant with other status checking methods.

Co-Authored-By: Alec Fong <[email protected]>
- Remove healthcheck import and registration from cmd.go
- Delete pkg/cmd/healthcheck directory and all related files
- Healthcheck command was identified as an additional removal request

This further streamlines the CLI by removing the backend health
checking functionality from the core CLI commands.

Co-Authored-By: Alec Fong <[email protected]>
…istency

- Update help text in create, start, stop, portforward, notebook, and scale commands
- Preserve 'local machine' and 'host machine' references as they refer to user's computer
- Addresses GitHub comment requesting terminology consistency

Co-Authored-By: Alec Fong <[email protected]>
)

var (
createLong = "Create a new Brev machine"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Appreciate the standardization of language.

Minor follow up:

  • Customer & internal documentation for product terminology

PreciselyAlyss
PreciselyAlyss previously approved these changes Jul 22, 2025
Copy link
Collaborator

@PreciselyAlyss PreciselyAlyss left a comment

Choose a reason for hiding this comment

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

  • Draft pull request for updating GL-hosted Brev docs for CLI changes
  • Get a review from someone that actual writes Go

fmt.Print("\n" + warningType(" Please keep this terminal open 🤙 "))

hello.TypeItToMeUnskippable27("\nClick here to go to your Jupyter notebook:\n\t 👉" + urlType("http://localhost:8888") + "👈\n\n\n")
fmt.Print("\nClick here to go to your Jupyter notebook:\n\t 👉" + urlType("http://localhost:8888") + "👈\n\n\n")
Copy link
Collaborator

Choose a reason for hiding this comment

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

$0.02: We can drop the "here" part of click here. People know they can click the url.

Suggested change
fmt.Print("\nClick here to go to your Jupyter notebook:\n\t 👉" + urlType("http://localhost:8888") + "👈\n\n\n")
fmt.Print("\nClick to go to your Jupyter notebook:\n\t 👉" + urlType("http://localhost:8888") + "👈\n\n\n")

- Change 'Click here to go to your Jupyter notebook' to 'Click to go to your Jupyter notebook'
- Addresses GitHub comment suggestion from PreciselyAlyss for cleaner UX text

Co-Authored-By: Alec Fong <[email protected]>
@devin-ai-integration
Copy link
Contributor Author

❌ Cannot revive Devin session - the session is too old. Please start a new session instead.

@cloin
Copy link
Contributor

cloin commented Nov 7, 2025

I merged improvements to the --help page that also removed broken commands. I think we can close this.

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.

3 participants