feat(settings): Codex Bağlama, on by default

Settings → Codex Bağlama runs the bundled bridge for an OpenAI Codex install on
the same computer: the IDE's models and combos appear in Codex and switching
models keeps the conversation. The IDE points Codex's openai_base_url at the
bridge only after the bridge answers, keeps it running across logins, and
removes every trace when the setting is turned off. A Codex that already uses
another base URL is left untouched.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HRDGW1LiKcDUZYUdKBoWYW
This commit is contained in:
yilsemandClaude Opus 5.5 committed 2026-10-09 15:59:39 +03:00
1 parent 1ce5ab82cf
commit dea67fc153
16 files changed
+2317 -2

No files matched your search

+80
View File
@@ -0,0 +1,80 @@
import type { CodexLinkError } from '../../electron/codex-link-types'
import { useI18n } from './context'
// Copy for Settings → Codex Link ("Codex Bağlama"). Kept beside the other
// AITURK-distribution strings (see ./aiturk): Turkish for `tr`, English for
// every other locale.
const en = {
nav: 'Codex Link',
title: 'Codex Link',
description:
'Adds the models and combos from AITURK IDE to the Codex on this computer and keeps the conversation context when you switch between models.',
unavailable: 'Codex Link is only available in the Windows desktop app.',
loadFailed: 'Could not read the Codex Link status.',
saveFailed: 'Could not change Codex Link.',
statusTitle: 'Status',
off: 'Codex Link is off. Codex runs with its own settings.',
codexFound: 'Codex was found on this computer.',
codexMissing: 'Codex was not found on this computer.',
foreign: 'Codex on this computer uses another bridge; its settings were not touched.',
venvPending: 'It will turn on once the IDE setup is complete.',
bridgeRunning: 'The bridge is running.',
bridgeStopped: 'The bridge is not running.',
models: (count: number) => (count === 1 ? '1 model added to Codex.' : `${count} models added to Codex.`),
signIn: 'No IDE session was found; sign in.',
errors: {
'autostart-failed': 'Could not set the bridge to start with Windows.',
'bridge-config-failed': 'Could not write the bridge settings.',
'bridge-missing': 'The bridge files are missing from this installation.',
'bridge-start-failed': 'The bridge could not be started; the Codex settings were left unchanged.',
'config-write-failed': 'Could not write the Codex settings file.',
'settings-write-failed': 'Could not save this setting.'
} satisfies Record<CodexLinkError, string>,
syncTitle: 'Sync now',
syncDesc: 'Checks the bridge and the Codex settings again.',
sync: 'Sync now',
syncing: 'Syncing…',
restartNote: 'Reopen Codex to see new models there.'
}
const tr: typeof en = {
nav: 'Codex Bağlama',
title: 'Codex Bağlama',
description:
"AITURK IDE'deki modelleri ve comboları bu bilgisayardaki Codex'e ekler; modeller arasında geçerken sohbet bağlamını korur.",
unavailable: 'Codex Bağlama yalnızca Windows masaüstü uygulamasında kullanılabilir.',
loadFailed: 'Codex Bağlama durumu okunamadı.',
saveFailed: 'Codex Bağlama değiştirilemedi.',
statusTitle: 'Durum',
off: 'Codex Bağlama kapalı. Codex kendi ayarlarıyla çalışıyor.',
codexFound: 'Bu bilgisayarda Codex bulundu.',
codexMissing: 'Bu bilgisayarda Codex bulunamadı.',
foreign: 'Bu bilgisayarda Codex başka bir köprü kullanıyor; ayarına dokunulmadı.',
venvPending: 'IDE kurulumu tamamlanınca etkinleşecek.',
bridgeRunning: 'Köprü çalışıyor.',
bridgeStopped: 'Köprü çalışmıyor.',
models: (count: number) => `Codex'e ${count} model eklendi.`,
signIn: 'IDE oturumu bulunamadı, giriş yapın.',
errors: {
'autostart-failed': 'Köprü Windows açılışında başlayacak şekilde ayarlanamadı.',
'bridge-config-failed': 'Köprü ayarları yazılamadı.',
'bridge-missing': 'Köprü dosyaları bu kurulumda bulunamadı.',
'bridge-start-failed': 'Köprü başlatılamadı; Codex ayarına dokunulmadı.',
'config-write-failed': 'Codex ayar dosyası yazılamadı.',
'settings-write-failed': 'Bu ayar kaydedilemedi.'
},
syncTitle: 'Şimdi eşitle',
syncDesc: 'Köprüyü ve Codex ayarını yeniden denetler.',
sync: 'Şimdi eşitle',
syncing: 'Eşitleniyor…',
restartNote: "Codex'te yeni modelleri görmek için Codex'i yeniden açın."
}
export type CodexLinkCopy = typeof en
export function useCodexLinkCopy(): CodexLinkCopy {
const { locale } = useI18n()
return locale === 'tr' ? tr : en
}