Skip to main content

Module process

Module process 

Source
Expand description

SSH process management and output handling

Handles:

  • Spawning SSH subprocess with proper I/O configuration
  • Reading and buffering SSH output
  • Applying syntax highlighting to output chunks
  • Managing non-interactive SSH commands

§Process Flow

  1. Detect if command is interactive or non-interactive
  2. Spawn SSH process with appropriate stdio configuration
  3. For interactive: read output in chunks, apply highlighting, display
  4. For non-interactive: passthrough directly without processing

Functions§

process_handler
Main process handler for SSH subprocess
spawn_ssh
Spawns an SSH process with the provided arguments.