feat(codex-link): AITURK work routing setting and beta.40
Server CI and Windows package / verify (push) Successful in 2m42s
Server CI and Windows package / windows-package (push) Successful in 6m21s

- Default routing rule (user decision, 15 Oct 2026): repeating/scheduled work goes to the AITURK IDE bot as a cron job; coding stays in Codex (itself or its subagents); 'Codex' or 'sen yap' keeps everything in Codex.
- Settings > Codex Bağlama: choice (recommended / send large work / never / custom text) with a text box and restore-default; written to bridge.json aiturk_hat.
- Bridge re-reads aiturk_hat when bridge.json changes: no restart. IDE apply keeps aiturk_hat instead of wiping it.
- Bridge version 20, IDE 1.0.0-beta.40. Jev untouched.
This commit is contained in:
yilsem committed 2026-10-15 02:18:18 +03:00
1 parent a7ba300448
commit 557e619499
16 files changed
+388 -26

No files matched your search

@@ -0,0 +1,24 @@
import { describe, expect, it } from 'vitest'
import { readIsHatti, writeIsHatti } from './is-hatti-settings'
describe('AITURK iş hattı settings', () => {
it('defaults to the recommended rule and reads older files the way the bridge does', () => {
expect(readIsHatti(null)).toEqual({ secim: 'onerilen', talimat: '' })
expect(readIsHatti('{"aiturk_hat":{"enabled":false}}').secim).toBe('kapali')
expect(readIsHatti('{"aiturk_hat":{"talimat":"x"}}')).toEqual({ secim: 'ozel', talimat: 'x' })
expect(readIsHatti('bozuk').secim).toBe('onerilen')
})
it('writes only aiturk_hat and keeps everything else', () => {
const raw = '{"port":8795,"aiturk_hat":{"enabled":false,"komut":"k"}}'
const out = JSON.parse(writeIsHatti(raw, { secim: 'buyuk', talimat: '' }))
expect(out).toEqual({ port: 8795, aiturk_hat: { komut: 'k', secim: 'buyuk', talimat: '' } })
})
it('rejects an empty custom text and unknown choices', () => {
expect(() => writeIsHatti(null, { secim: 'ozel', talimat: ' ' })).toThrow()
expect(() => writeIsHatti(null, { secim: 'x', talimat: '' })).toThrow()
expect(() => writeIsHatti('{bozuk', { secim: 'onerilen', talimat: '' })).toThrow()
})
})