You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
PowerShell profile not loaded and inconsistent shell versions on Windows #17393
OpenCode has multiple issues with PowerShell profile loading on Windows:
1. Inconsistent PowerShell version:
- bash tool → PowerShell 7.5.4
- Shell input box / Agent responses → PowerShell 5.1
2. Profile not loaded:
- OpenCode's Shell input box executes commands without loading PowerShell profile
- Custom functions (ll, la, lla), aliases, and environment variables are unavailable
- Even though "PowerShell 5 配置文件已加载" message appears, the profile functions are not actually loaded
3. Expected behavior:
- Should load PowerShell profile regardless of which shell is used
- Should use consistent PowerShell version (preferably the one OpenCode was launched from)
Environment:
- Windows
- PowerShell 7.5.4 (pwsh)
- PowerShell 5.1 (powershell)
- OpenCode launched from PowerShell 7
Activity
github-actions commentedon Mar 13, 2026
This issue might be a duplicate of existing issues. Please check:
Please consider whether #17372 already covers your report, or if you'd like to close one and consolidate the details into the other.
github-actions commentedon Jul 3, 2026
To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.