Skip to content

feat(profile): add opencode profile and improve config handling#24

Merged
Pierozi merged 3 commits intomainfrom
feat/opencode
Feb 17, 2026
Merged

feat(profile): add opencode profile and improve config handling#24
Pierozi merged 3 commits intomainfrom
feat/opencode

Conversation

@Pierozi
Copy link
Contributor

@Pierozi Pierozi commented Feb 17, 2026

Summary

  • Adds built-in opencode profile for OpenCode tooling support with access to config, cache, and state directories
  • Fixes inherit_global configuration to be properly respected when using -c flag
  • Includes comprehensive test coverage for both new profile and config inheritance behavior

Test plan

  • Unit tests for opencode profile loading and path validation
  • Integration tests for inherit_global configuration with -c flag
  • Manual test: cargo build && cargo run -- -p opencode <command>
  • Verify sandbox-exec profile includes opencode paths in dry-run mode

- Test merging global and project configs when inherit_global=true
- Test skipping global config when inherit_global=false
- Test that inherit_global is ignored in custom config files
When -c specifies a config file, treat it as a project config and check
inherit_global to decide if the default global config should be merged.
Previously, the -c file was always loaded as global config, making
inherit_global ineffective.

Scenarios now working correctly:
- -c with inherit_global=true: merges with ~/.config/sx/config.toml
- -c with inherit_global=false: uses config standalone
- -c with inherit_base=false: full custom control over allowed paths
- No -c flag: loads global config + project .sandbox.toml as before
Adds built-in opencode profile with access to opencode config, cache, and state directories. Includes updates to CLI help text, config template documentation, and comprehensive tests.
@Pierozi Pierozi merged commit 4f3ab60 into main Feb 17, 2026
5 of 6 checks passed
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

Comments