Skip to content

.env files loaded without warning #2033

@pbjorklund

Description

@pbjorklund

When GH_TOKEN is set as an environment variable, it conflicts with gh CLI authentication when running commands through opencode's bash tool.

Opencode uses Bun runtime (via bun build --compile) which automatically loads .env files from the working directory. Variables like GH_TOKEN in .env get inherited by child processes, causing gh CLI authentication conflicts.

Should perhaps warn user when using .env vars that was perhaps not meant to be loaded by opencode.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions