Commit Graph

18 Commits

Author SHA1 Message Date
Catriel Müller 2aa1b95074 refactor: resolve comments 2026-05-18 11:45:36 -03:00
Mark IJbema ee3ee5b06b fix(upstream-merge): always reconcile package.json post-merge
git rerere learns conflict resolutions from past upstream merges and
replays them on the next merge. When past resolutions used the buggy
mergeWithNewestVersions ordering, rerere auto-resolves package.json
files with stale content before transformConflictedPackageJson ever
gets a chance to run — so the fixed merge logic never reaches the
file.

Add reconcileAllPackageJson, which runs after every merge (clean,
auto-resolved, or partially conflicted) and rewrites every package.json
that the merge touched from the kilo branch's pre-merge HEAD and the
opencode compat branch using the same merge logic. Files that are
still conflicted are skipped so manual resolution isn't silently
overwritten.

This makes our merge logic the source of truth for package.json
content, regardless of what rerere or git's textual merge produced.
2026-05-11 10:02:35 +02:00
Mark IJbema d79664f084 fix(upstream-merge): preserve ours' key order in package.json dep merge
Seeding the result with theirs' keys and appending ours-only keys at the
end caused kilo-only deps (e.g. rotating-file-stream in packages/core)
to relocate from the middle of the deps block to the end during the
pre-merge transform. Git's textual 3-way merge then saw ours keeping
the line in place and theirs adding the same key elsewhere, producing
a duplicate JSON key in the merged file.

Iterate ours first so kilo-only deps stay in their original position,
then append any theirs-only keys at the end.
2026-05-11 10:02:34 +02:00
Mark IJbema a156e7a98d chore(upstream): preserve & prune root package.json entries on merge
The transform that materialises the 'kilo compat for vX.Y.Z' commit during
an upstream merge takes upstream's package.json wholesale and re-applies a
hand-picked list of Kilo scripts. That list was incomplete: it only covered
`extension`, `changeset`, `changeset:version`, `test`, and `test:ci`, so
every merge silently dropped Kilo's `postinstall` tail (`&& bun run
script/setup-git.ts`) and the `dev-setup` root shortcut, and it never
pruned upstream-only scripts (`dev:desktop` / `dev:web` / `dev:console`)
or upstream-only catalog entries (`@sentry/solid`,
`@sentry/vite-plugin`) whose target packages Kilo doesn't ship.

- replace the per-script if-blocks with data-driven PRESERVE_SCRIPTS
- add DELETE_UPSTREAM_SCRIPTS for scripts that reference packages Kilo
  doesn't ship
- add DELETE_UPSTREAM_CATALOG for catalog entries with zero Kilo consumers
- apply the same policy in both transformPackageJson (conflict path) and
  transformAllPackageJson (pre-merge sweep path) — previously the
  pre-merge sweep was missing `changeset` / `changeset:version`
  preservation
- new tests covering preservation, deletion, opencode test scripts, and
  the catalog pruning
2026-05-11 10:02:34 +02:00
kiloconnect[bot] d22d08bbce chore: remove stale desktop package references 2026-05-04 15:00:59 +00:00
Catriel Müller d039bdf6c3 feat: test runner 2026-04-15 15:11:33 -03:00
Catriel Müller 9a023e8db8 fix: preserve changelog script 2026-04-13 14:04:58 -03:00
Catriel Müller 54c25a6d45 refactor: perserve extension action 2026-04-11 13:51:27 -03:00
Catriel Müller 1cb1442129 fix: main package name 2026-04-11 13:42:20 -03:00
Catriel Müller 43a79f23b1 refactor: fix package.json bin upstream merge 2026-03-18 08:38:19 -03:00
Catriel Müller a01e8e5bfb feat: merge opencode v1.2.19 2026-03-17 07:46:46 -03:00
Catriel Müller 5b796226c3 refactor: consider kilocode change markers on merge 2026-03-17 07:27:25 -03:00
Mark IJbema 9a0ac0c0ee docs: update default branch references from dev to main
- Update AGENTS.md to reflect main as default branch
- Update GitHub Actions workflows to trigger on main branch
- Update publish scripts to cherry-pick from origin/main
- Update upstream merge scripts and documentation
- Update CONTRIBUTING.md links in PR standards workflow
- Fix disabled workflow and documentation links

All development commands (bun dev, npm run dev) and external services
(models.dev, ai-sdk.dev) remain unchanged as they are unrelated to branch names.
2026-02-23 11:19:39 +01:00
Catriel Müller f259b6a90b chore: remove hosted platform packages and update upstream merge config
Remove 8 hosted platform packages that are not needed for the CLI-focused fork:
- infra/ (SST infrastructure)
- packages/console/ (console web app + backend)
- packages/enterprise/ (enterprise/teams platform)
- packages/web/ (Astro documentation site)
- packages/slack/ (Slack integration)
- packages/function/ (API workers)
- packages/docs/ (static docs)
- packages/identity/ (brand assets)

Update upstream merge configuration to prevent these packages from being
re-added during future merges from opencode upstream:
- Add all deleted folders/files to skipFiles in config.ts
- Add Vouch-related files to skip list (VOUCHED.md, vouch workflows)
- Update transform-package-json.ts to preserve Kilo's workspace config
- Remove slack/web references from transform lists

Update supporting files:
- Remove console/* and slack from package.json workspaces
- Remove sst and @aws-sdk/client-s3 dependencies
- Update AGENTS.md package references
- Clean .prettierignore of deleted package references
- Add logs/.gitignore to keep folder empty

Result: 310,297 lines deleted, 11 npm packages removed, typecheck passing
2026-02-11 13:05:19 -03:00
Catriel Müller e5f92bc59d feat: improve package.json deps and overrides 2026-02-05 14:01:08 -03:00
Catriel Müller da1f793a68 feat: preserve kilo-i18n 2026-02-05 13:31:47 -03:00
Catriel Müller 033490587f refactor: improve premerge transforms 2026-02-05 13:31:16 -03:00
Catriel Müller 0960e6a85b refactor: improve upstream script 2026-02-05 13:31:16 -03:00