mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-01-31 06:42:03 +00:00
feat: add OpenCode CLI support with status endpoint
- Implemented OpenCode CLI installation and authentication status check. - Added new route for OpenCode status in setup routes. - Updated HttpApiClient to include method for fetching OpenCode status. - Enhanced system paths to include OpenCode's default installation directories. This commit introduces functionality to check the installation and authentication status of the OpenCode CLI, improving integration with the overall system.
This commit is contained in:
@@ -1034,6 +1034,8 @@ export function getOpenCodeCliPaths(): string[] {
|
||||
const appData = process.env.APPDATA || path.join(homeDir, 'AppData', 'Roaming');
|
||||
const localAppData = process.env.LOCALAPPDATA || path.join(homeDir, 'AppData', 'Local');
|
||||
return [
|
||||
// OpenCode's default installation directory
|
||||
path.join(homeDir, '.opencode', 'bin', 'opencode.exe'),
|
||||
path.join(homeDir, '.local', 'bin', 'opencode.exe'),
|
||||
path.join(appData, 'npm', 'opencode.cmd'),
|
||||
path.join(appData, 'npm', 'opencode'),
|
||||
@@ -1060,6 +1062,8 @@ export function getOpenCodeCliPaths(): string[] {
|
||||
const pnpmHome = process.env.PNPM_HOME || path.join(homeDir, '.local', 'share', 'pnpm');
|
||||
|
||||
return [
|
||||
// OpenCode's default installation directory
|
||||
path.join(homeDir, '.opencode', 'bin', 'opencode'),
|
||||
// Standard locations
|
||||
path.join(homeDir, '.local', 'bin', 'opencode'),
|
||||
'/opt/homebrew/bin/opencode',
|
||||
|
||||
Reference in New Issue
Block a user