feat: lifecycle commands, output formatting, and show-commands mode#54
Merged
Conversation
Add harness status/logs/stop/start commands wrapping openshell sandbox lifecycle operations. Add Header() and Table() to status module for structured output. Add --show-commands flag that prints openshell CLI commands to stdout as a teaching aid, decoupled from execution so it survives the future gRPC migration.
Quiet noisy kubectl/helm passthrough output in deploy (CRD install, SCC grants, rollout status now captured instead of streamed). Switch phase headers from === Section === to Header() with underline. Fix registerProviders printing "Done. Launch a sandbox with: harness up --local" when called from up --remote by adding a standalone parameter. Add top-level context lines (agent name, image) at the start of up flows. Remove inconsistent spacing and stray fmt.Println() calls.
969bba9 to
df5fbbd
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
harness status/logs/stop/startcommands wrapping openshell sandbox lifecycle operations (NemoClaw gap analysis item feat: update for latest OpenShell with Helm chart and provider system #1 from deep research)Header()andTable()to the status module for structured, column-aligned output--show-commandsflag that prints openshell CLI commands to stdout as a teaching aid, decoupled from execution viaShowEquivalentCmd()so it survives the future gRPC migrationDetails
Lifecycle commands: Four new Gateway interface methods (
SandboxStatus,SandboxLogs,SandboxStop,SandboxStart) with CLI implementations.stopandstartauto-select when exactly one sandbox is running.logssupports--follow/-f.Output formatting:
status.Header(title)prints a title with underline.status.Table(headers, rows)computes column widths and prints aligned output.Show commands:
status.ShowCommandsis independent fromstatus.Verbose. When--show-commandsis set, every openshell CLI invocation prints to stdout. For the future gRPC gateway,ShowEquivalentCmd()can display the equivalent CLI command even when executing via gRPC.Test plan
go build ./...compilesgo vet ./...cleango test ./internal/status/passes (Header, Table, ShowCommands tests)go test ./internal/gateway/passes (SandboxStatus, Stop, Start, Logs tests)harness statuswith/without active gatewayharness --show-commands createshows commands on stdout