Summary
V2 does not preserve a number of non-experimental environment-variable behaviors supported by V1. Some variables remain declared in packages/core/src/flag/flag.ts but have no active V2 consumer; others disappeared with their V1 subsystem.
This is the umbrella issue for the broader compatibility gap reported narrowly in #36837.
Audited against:
- V1 /
dev: b6478dcebf1da4a559055c702c62b9294c41afdb
- V2:
ba1f3d3d32690879fbed156d53570b8652e254ed
Completely ignored in V2
Configuration and permissions
Sharing and authentication
Plugins, skills, and compatibility discovery
Other runtime controls
Partially handled or changed
Intentional change
OPENCODE_TUI_CONFIG is not included in the compatibility checklist. V2 intentionally moved to one global cli.json and does not support arbitrary or project-local TUI configuration.
Expected behavior
Per the V1-to-V2 migration contract, non-API V1 functionality is intended to remain compatible. For every item above, either:
- restore the V1 behavior in V2 and add coverage, or
- explicitly decide that the behavior is obsolete, remove stale declarations/documentation, and document the migration path.
Summary
V2 does not preserve a number of non-experimental environment-variable behaviors supported by V1. Some variables remain declared in
packages/core/src/flag/flag.tsbut have no active V2 consumer; others disappeared with their V1 subsystem.This is the umbrella issue for the broader compatibility gap reported narrowly in #36837.
Audited against:
dev:b6478dcebf1da4a559055c702c62b9294c41afdbba1f3d3d32690879fbed156d53570b8652e254edCompletely ignored in V2
Configuration and permissions
OPENCODE_CONFIG— explicit config-file overrideOPENCODE_CONFIG_CONTENT— inline config injectionOPENCODE_PERMISSION— JSON permission overrideOPENCODE_DISABLE_AUTOCOMPACT— force-disable automatic compactionOPENCODE_DISABLE_PRUNE— force-disable compaction pruningOPENCODE_FAKE_VCS— override detected VCSSharing and authentication
OPENCODE_AUTO_SHARE— force automatic sharingOPENCODE_DISABLE_SHARE— globally disable sharingOPENCODE_AUTH_CONTENT— in-memory auth JSON overridePlugins, skills, and compatibility discovery
OPENCODE_PURE— suppress external plugins/runtime integrationsOPENCODE_DISABLE_DEFAULT_PLUGINS— suppress built-in pluginsOPENCODE_DISABLE_EXTERNAL_SKILLS— suppress external skill discoveryOPENCODE_DISABLE_CLAUDE_CODE— suppress Claude compatibility discoveryOPENCODE_DISABLE_CLAUDE_CODE_PROMPT— suppress Claude prompt discoveryOPENCODE_DISABLE_CLAUDE_CODE_SKILLS— suppress Claude skill discoveryOPENCODE_PLUGIN_META_FILE— override plugin metadata pathOther runtime controls
OPENCODE_DISABLE_LSP_DOWNLOAD— prevent language-server installationOPENCODE_ENABLE_QUESTION_TOOL— control question-tool availabilityOPENCODE_DISABLE_EMBEDDED_WEB_UI— suppress embedded UI routesOPENCODE_AUTO_HEAP_SNAPSHOT— enable automatic heap snapshotsOPENCODE_ALWAYS_NOTIFY_UPDATE— force update notificationsPartially handled or changed
OPENCODE_DISABLE_PROJECT_CONFIGonly suppresses projectAGENTS.md. V2 still loads projectopencode.json(c)and project.opencode,.claude, and.agentsdirectories. See core: OPENCODE_DISABLE_PROJECT_CONFIG is ignored in v2 #36837.OPENCODE_CONFIG_DIRchanges the global config root in V2 instead of acting as the additional explicit config source it was in V1. Confirm and restore the intended compatibility semantics.OPENCODE_SERVER_PASSWORDis still accepted, but the V2 CLI prefersOPENCODE_PASSWORDand managed-server credential propagation differs from V1.OPENCODE_SERVER_USERNAMEonly affects manually configured server authentication, not the new managed-service credential path.Intentional change
OPENCODE_TUI_CONFIGis not included in the compatibility checklist. V2 intentionally moved to one globalcli.jsonand does not support arbitrary or project-local TUI configuration.Expected behavior
Per the V1-to-V2 migration contract, non-API V1 functionality is intended to remain compatible. For every item above, either: