Skip to content

claude: honor ONCTL_CLOUD, don't force boxes when -p is absent - #1214

Merged
cdalar merged 1 commit into
mainfrom
claude-honor-onctl-cloud
Oct 22, 2026
Merged

cdalar merged 1 commit into
mainfrom
claude-honor-onctl-cloud

Conversation

@cdalar

@cdalar cdalar commented Oct 22, 2026

Copy link
Copy Markdown
Owner

Why

ONCTL_CLOUD=ac onctl claude created a hosted box on the boxes service, not an Apple container on this machine. The claude command set the provider to boxes whenever -p was absent, without looking at ONCTL_CLOUD.

What

The boxes default now applies only when neither -p nor ONCTL_CLOUD picks a provider. -p still wins over the env var, as for every other command. Pulled into a small claudeProvider function with a table test that spells out the intent.

Verified

  • Before: ONCTL_CLOUD=ac onctl claude --detach printed "Creating claude-onctl (claude-agent, medium)" and a box appeared in onctl -p boxes ls; container ls unchanged.
  • After: it printed "Creating claude-onctl on ac...", installed tmux/git/Claude Code, copied the project, and container ls shows claude-onctl running with a claude tmux session and the project at /Users/cd/cdalar/onctl.
  • go test ./cmd/ passes.

🤖 Generated with Claude Code

https://claude.ai/code/session_01SB788HixFrKbYGCxDRi8fX

onctl claude defaulted to boxes whenever -p wasn't given, overriding
ONCTL_CLOUD: `ONCTL_CLOUD=ac onctl claude` created a hosted box on the
boxes service instead of an Apple container on this machine. The boxes
default now applies only when neither -p nor ONCTL_CLOUD picks a
provider, as for every other command.

Claude-Session: https://claude.ai/code/session_01SB788HixFrKbYGCxDRi8fX
@cdalar
cdalar enabled auto-merge (squash) October 22, 2026 04:39
@cdalar
cdalar merged commit 870b760 into main Oct 22, 2026
12 checks passed
@codecov

codecov Bot commented Oct 22, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 80.00000% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 45.24%. Comparing base (ae72d05) to head (517bd55).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
cmd/root.go 80.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1214      +/-   ##
==========================================
+ Coverage   45.22%   45.24%   +0.01%     
==========================================
  Files          75       75              
  Lines        8732     8735       +3     
==========================================
+ Hits         3949     3952       +3     
  Misses       4782     4782              
  Partials        1        1              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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

⌂ 换网址