Skip to content

Conversation

@involvex
Copy link

@involvex involvex commented Dec 3, 2025

Context
This PR addresses multiple issues and enhancements across the Kilo Code CLI:

Fixed critical TypeScript compilation errors that were preventing the CLI from building properly
Resolved package installation issues that were breaking npm installs of the published CLI
Enhanced the config command with modern autocomplete and direct argument-based configuration
Improved the StatusBar component with real-time system monitoring (CPU, memory, tokens)
Implementation

  1. TypeScript Fixes (cli/src/commands/chat.ts)
    Fixed spread operator error by properly typing SavedChatSession.messages as CliMessage[] instead of unknown[]
    Added type casting to resolve type mismatches between ExtensionMessage[] and CliMessage[]
    Maintained backward compatibility with existing chat session persistence
  2. Package Configuration Fixes (cli/package.json)
    Removed problematic workspace: dependency references that were causing npm installation failures
    These dependencies (@roo-code/* packages) are bundled during the build process and don't need to be external dependencies
    Fixed the "Unsupported URL Type 'workspace:'" npm error
  3. Config Command Enhancement (cli/src/commands/config.ts)
    Added autocomplete providers for all config settings (mode, telemetry, theme, provider, auto-approval)
    Implemented argument-based configuration allowing direct commands like /config mode code or /config telemetry false
    Maintained backward compatibility with existing interactive menu (/config or /config menu)
    Added comprehensive validation and error handling for all config options
    Conditional autocomplete that shows relevant options based on the selected setting
  4. StatusBar System Monitoring (cli/src/ui/components/StatusBar.tsx)
    Added real-time CPU usage tracking using Node.js os.cpus() API with proper differential calculations
    Added memory usage monitoring with total/used memory display using os.totalmem() and os.freemem()
    Integrated token count display from existing context usage system
    Performance optimized with 2-second update intervals and proper cleanup
    User-friendly formatting with automatic unit conversion (B/KB/MB/GB/TB) and percentage displays
    Color-coded indicators for system health (green/yellow/red based on usage thresholds)
    Error handling to gracefully handle system API failures
  5. Code Quality Improvements
    Fixed ESLint issues (unused imports, prefer-const, explicit any types)
    Improved type safety throughout the codebase
    Added proper error boundaries and fallbacks
    Basic status bar with project, mode, model, and context Enhanced status bar with real-time CPU, memory, and token metrics
    How to Test
    Testing Config Command Enhancements:
    Run the CLI and try /config - should show interactive menu
    Try /config mode - should show autocomplete for available modes
    Try /config mode code - should switch to code mode immediately
    Try /config telemetry false - should disable telemetry
    Try /config theme dark - should set theme to dark
    Try invalid inputs - should show appropriate error messages
    Testing StatusBar Enhancements:
    Start the CLI and observe the status bar
    The status bar should now show CPU usage (e.g., "CPU: 45.2%")
    Memory usage should display (e.g., "RAM: 2.1GB/16.0GB (13.1%)")
    Token count should appear when there are tokens used (e.g., "1.2K tokens")
    Colors should change based on usage levels (green < 60%, yellow 60-80%, red > 80%)
    Metrics should update every 2 seconds
    Testing Package Installation:
    The CLI should now install properly via npm install -g @involvex/kilocode-cli
    No more "Unsupported URL Type 'workspace:'" errors
    Testing TypeScript Compilation:
    Run npm run check-types in the cli directory
    Should pass without any TypeScript errors
    Get in Touch
    Feel free to reach out in the Kilo Code Discord if you have questions about these changes!
    Involvex on Kilo Code Discord
image image image image

…ities

Introduce uniform tab indentation across project files
Implement new CLI commands for system information and directory management
Migrate CLI package to updated naming convention
Enhance configuration handling with interactive menu system

BREAKING CHANGE: CLI package renamed from @kilocode/cli to @involvex/kilocode-cli
- Implement /chat command for saving, listing, and resuming chat sessions
- Add /clearcontext command to clear all conversation state and messages
- Update command registry to include new chat and clearcontext commands
- Bump CLI version to 0.10.4
- Fix pre-push hook to use pnpm instead of pnpm.cmd on Windows
- Enhance /config command to support direct setting of mode, telemetry, theme, provider, and auto-approval
- Add autocomplete providers for each setting with validation
- Maintain backward compatibility with interactive menu via /config menu
- Bump version to 0.10.6 for the new functionality
- Add CPU usage, memory usage, and token count to the status bar UI
- Update about command to display current version
- Bump version to 0.10.7

This enhances the CLI's status bar with real-time system performance metrics, improving user awareness of resource usage during operations. The version display in the about command ensures users can easily check the current CLI version.
Update package name from @involvex/kilocode-cli to @kilocode/cli across
package.json, turbo.json, and related scripts. Also adjust the about
command message to reflect the fork status.
@changeset-bot
Copy link

changeset-bot bot commented Dec 3, 2025

🦋 Changeset detected

Latest commit: a863f33

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
@involvex/kilocode-cli Minor
kilo-code Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

involvex and others added 3 commits December 3, 2025 06:36
Renamed the `@kilocode/cli` package to `@involvex/kilocode-cli` across all
relevant files, including package definitions, CI workflows, and build
configurations.

Normalized file paths in the VSCode host to ensure consistent document
lookups across different operating systems.

Updated `StaticSettingsService` error handling for improved compatibility.

Adjusted build configurations, `tsconfig.json` includes, and CI/CD
workflows to reflect the package name change and other improvements.

Enhanced test assertions for worktree path generation.
- Replace jq-based version update with Node.js script for better reliability
- Add manual changeset processing script to bypass GitHub API requirements
- Update package versions and clean up temporary files
- Add TypeScript path for types package in CLI tsconfig
- Bump CLI version to 0.10.9 and update dependencies in types package
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