opencode icon indicating copy to clipboard operation
opencode copied to clipboard

Will not read env even with config set

Open PilotDevo opened this issue 2 weeks ago • 5 comments

Description

There seems to be an issues with reading env files. i've written the config file to allow however there still is a block from allowing the agent into the file. any suggestions?

OpenCode version

1.0.152

Steps to reproduce

opencode /session any "analyze our env files for any inconsistencies" The user has blocked you from reading /home/devo/projects/aiq/v2/platform/.env, DO NOT make further attempts to read it

Screenshot and/or share link

No response

Operating System

No response

Terminal

No response

PilotDevo avatar Dec 13 '25 13:12 PilotDevo

This issue might be a duplicate of existing issues. Please check:

  • #4969: Overly restrictive .env file blocking prevents reading legitimate files

Feel free to ignore if none of these address your specific case.

github-actions[bot] avatar Dec 13 '25 13:12 github-actions[bot]

yeah rn it’s blocked ill make it configurable tho

as a work around you can enter shell mode (type ! into prompt)

and then do:

cat .env

rekram1-node avatar Dec 13 '25 17:12 rekram1-node