fix(cliproxy): make version cache backend-specific for proper switching

- Add backend parameter to version cache functions (read/write/path)
- Store cache at bin/{backend}/.version-cache.json instead of shared location
- Pass backend through checkForUpdates() and BinaryManager
- Add refetchType: 'all' to force immediate query refetch on backend change
- Add cliproxy-server-config query invalidation for consistency
This commit is contained in:
kaitranntt
2026-01-23 14:40:40 -05:00
parent 0511c5e2fd
commit a41fd2a093
4 changed files with 34 additions and 17 deletions
+6 -1
View File
@@ -85,7 +85,12 @@ export class BinaryManager {
/** Check for updates by comparing installed version with latest release */
async checkForUpdates(): Promise<UpdateCheckResult> {
return checkForUpdates(this.config.binPath, this.config.version, this.config.verbose);
return checkForUpdates(
this.config.binPath,
this.config.version,
this.config.verbose,
this.backend
);
}
/** Get full path to binary executable */