Skip to content

Phase 2e: Port keyboard input and build orchestration to Rust #22

Closed

Description

@zackees

Part of #14
Depends on Phase 2b (#19), Phase 2c (#20), Phase 2d (#21)

Goal

Port keyboard.py, compile_native.py, build_service.py, and build_types.py to Rust. The Rust CLI now owns the main event loop and calls Python internal_wasm_build.py via subprocess for actual compilation.

Tasks

  • Port keyboard input handling using crossterm crate (space bar detection for rebuild trigger)
  • Port BuildRequest, BuildResult, BuildMode types to Rust structs
  • Port BuildService orchestration: cold vs incremental detection, toolchain reuse
  • Implement subprocess call to python -m fastled.toolchain.internal_wasm_build for actual WASM compilation
  • Port watch-mode main loop: watch files + keyboard input + rebuild on change
  • Add Rust tests for build service logic
  • Remove Python modules and update imports

Acceptance criteria

  • fastled --just-compile examples/Wasm works entirely from Rust CLI (calling Python for build only)
  • Watch mode works: file changes and space bar trigger rebuilds
  • Cold/incremental detection works correctly
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions