feat: removed chunk-mode modules and read/edit entrypoints from pi-natives

- Removed `pi-natives` chunk language classifier modules and all core chunk subsystems (kind, state, render, edit, resolve).
- Removed chunk-mode CLI/read/edit entrypoints, including `read` command and chunk mode registration/prompt tooling.
- Removed chunk selectors from `read` and `grep` tools, switching behavior to raw/L-range handling.
- Fixed poll wait parsing to keep defaulting to `30s` when the provided value is empty.
This commit is contained in:
can1357
2026-04-26 08:19:02 +02:00
parent a227adad1b
commit 5ea1d55e56
88 changed files with 49 additions and 30753 deletions
+1 -2
View File
@@ -1,13 +1,12 @@
import { $env, $flag } from "@oh-my-pi/pi-utils";
export type EditMode = "replace" | "patch" | "hashline" | "chunk" | "vim" | "apply_patch" | "atom";
export type EditMode = "replace" | "patch" | "hashline" | "vim" | "apply_patch" | "atom";
export const DEFAULT_EDIT_MODE: EditMode = "hashline";
const EDIT_MODE_IDS = {
apply_patch: "apply_patch",
atom: "atom",
chunk: "chunk",
hashline: "hashline",
patch: "patch",
replace: "replace",
@@ -7,7 +7,6 @@ import { resolveEditMode } from "./edit-mode";
export interface FileDisplayMode {
lineNumbers: boolean;
hashLines: boolean;
chunked: boolean;
}
/** Session-like object providing settings and tool availability for display mode resolution. */
@@ -33,10 +32,8 @@ export function resolveFileDisplayMode(session: FileDisplayModeSession, options?
const usesHashLineAnchors = editMode === "hashline" || editMode === "atom";
const raw = options?.raw === true;
const hashLines = !raw && hasEditTool && usesHashLineAnchors && settings.get("readHashLines") !== false;
const chunked = !raw && hasEditTool && editMode === "chunk";
return {
hashLines,
lineNumbers: !raw && (hashLines || settings.get("readLineNumbers") === true),
chunked,
};
}