diff --git a/CONTRIBUTING.md b/.github/CONTRIBUTING.md similarity index 100% rename from CONTRIBUTING.md rename to .github/CONTRIBUTING.md diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index cbfabad4d..08ce81990 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -33,7 +33,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version-file: .nvmrc + node-version-file: package.json - name: Setup pnpm uses: pnpm/action-setup@v4 diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 1472f7472..e85f321bc 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -22,7 +22,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version-file: .nvmrc + node-version-file: package.json - name: Setup pnpm uses: pnpm/action-setup@v4 diff --git a/.github/workflows/release-cut.yml b/.github/workflows/release-cut.yml index c023bd3fd..2a8159c92 100644 --- a/.github/workflows/release-cut.yml +++ b/.github/workflows/release-cut.yml @@ -60,7 +60,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version-file: .nvmrc + node-version-file: package.json - name: Configure git author run: | diff --git a/.github/workflows/release-rc.yml b/.github/workflows/release-rc.yml index 3641ba6fa..3ebdc8c2b 100644 --- a/.github/workflows/release-rc.yml +++ b/.github/workflows/release-rc.yml @@ -40,7 +40,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version-file: .nvmrc + node-version-file: package.json - name: Configure git author run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 43a9170d2..bda260be9 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -122,7 +122,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version-file: .nvmrc + node-version-file: package.json cache: pnpm # Why: release builds hit the same native-module postinstall path as diff --git a/.nvmrc b/.nvmrc deleted file mode 100644 index a45fd52cc..000000000 --- a/.nvmrc +++ /dev/null @@ -1 +0,0 @@ -24 diff --git a/patches/@xterm__addon-ligatures@0.11.0-beta.198.patch b/config/patches/@xterm__addon-ligatures@0.11.0-beta.198.patch similarity index 100% rename from patches/@xterm__addon-ligatures@0.11.0-beta.198.patch rename to config/patches/@xterm__addon-ligatures@0.11.0-beta.198.patch diff --git a/patches/node-pty@1.1.0.patch b/config/patches/node-pty@1.1.0.patch similarity index 100% rename from patches/node-pty@1.1.0.patch rename to config/patches/node-pty@1.1.0.patch diff --git a/scripts/build-relay.mjs b/config/scripts/build-relay.mjs similarity index 100% rename from scripts/build-relay.mjs rename to config/scripts/build-relay.mjs diff --git a/config/scripts/install-dev-cli.mjs b/config/scripts/install-dev-cli.mjs index 1c74e797d..ddd522682 100644 --- a/config/scripts/install-dev-cli.mjs +++ b/config/scripts/install-dev-cli.mjs @@ -6,8 +6,8 @@ import { execFileSync } from 'node:child_process' import path from 'node:path' import { fileURLToPath } from 'node:url' -const repoRoot = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '../..') -const source = path.join(repoRoot, 'bin', 'orca-dev') +const scriptDir = path.dirname(fileURLToPath(import.meta.url)) +const source = path.join(scriptDir, 'orca-dev') const commandPath = process.platform === 'darwin' || process.platform === 'linux' diff --git a/bin/orca-dev b/config/scripts/orca-dev similarity index 95% rename from bin/orca-dev rename to config/scripts/orca-dev index 97acbf9f1..47bdb1c5b 100755 --- a/bin/orca-dev +++ b/config/scripts/orca-dev @@ -10,7 +10,7 @@ while [ -L "$SOURCE" ]; do [[ "$SOURCE" != /* ]] && SOURCE="$DIR/$SOURCE" done SCRIPT_DIR="$(cd "$(dirname "$SOURCE")" && pwd)" -REPO_ROOT="$(cd "$SCRIPT_DIR/.." && pwd)" +REPO_ROOT="$(cd "$SCRIPT_DIR/../.." && pwd)" CLI_ENTRY="$REPO_ROOT/out/cli/index.js" if [ ! -f "$CLI_ENTRY" ]; then diff --git a/scripts/rebuild-native-deps.mjs b/config/scripts/rebuild-native-deps.mjs similarity index 100% rename from scripts/rebuild-native-deps.mjs rename to config/scripts/rebuild-native-deps.mjs diff --git a/package.json b/package.json index 6a1bfd5fc..106e1af51 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "author": "stablyai", "bin": { "orca": "./out/cli/index.js", - "orca-dev": "./bin/orca-dev" + "orca-dev": "./config/scripts/orca-dev" }, "main": "./out/main/index.js", "scripts": { @@ -24,13 +24,13 @@ "typecheck": "tsc --noEmit -p config/tsconfig.node.json --composite false && tsc --noEmit -p config/tsconfig.cli.json --composite false && tsc --noEmit -p config/tsconfig.web.json --composite false", "start": "electron-vite preview", "dev": "node config/scripts/run-electron-vite-dev.mjs", - "build:relay": "node scripts/build-relay.mjs", + "build:relay": "node config/scripts/build-relay.mjs", "build:cli": "tsc -p config/tsconfig.cli.json --outDir out --composite false --incremental false && node config/scripts/install-dev-cli.mjs", "build:electron-vite": "node config/scripts/run-electron-vite-build.mjs", "build": "pnpm run typecheck && pnpm run build:relay && pnpm run build:electron-vite && pnpm run build:cli", "build:release": "pnpm run build:relay && pnpm run build:electron-vite && pnpm run build:cli", - "postinstall": "pnpm rebuild electron && node scripts/rebuild-native-deps.mjs", - "rebuild:electron": "node scripts/rebuild-native-deps.mjs", + "postinstall": "pnpm rebuild electron && node config/scripts/rebuild-native-deps.mjs", + "rebuild:electron": "node config/scripts/rebuild-native-deps.mjs", "build:unpack": "pnpm run build && electron-builder --config config/electron-builder.config.cjs --dir", "build:win": "pnpm run build && electron-builder --config config/electron-builder.config.cjs --win", "build:icons": "bash resources/icon-source/generate.sh", @@ -149,6 +149,9 @@ "oxfmt --write" ] }, + "engines": { + "node": "24" + }, "packageManager": "pnpm@10.24.0+sha512.01ff8ae71b4419903b65c60fb2dc9d34cf8bb6e06d03bde112ef38f7a34d6904c424ba66bea5cdcf12890230bf39f9580473140ed9c946fef328b6e5238a345a", "pnpm": { "onlyBuiltDependencies": [ @@ -160,8 +163,8 @@ "node-pty" ], "patchedDependencies": { - "node-pty@1.1.0": "patches/node-pty@1.1.0.patch", - "@xterm/addon-ligatures@0.11.0-beta.198": "patches/@xterm__addon-ligatures@0.11.0-beta.198.patch" + "node-pty@1.1.0": "config/patches/node-pty@1.1.0.patch", + "@xterm/addon-ligatures@0.11.0-beta.198": "config/patches/@xterm__addon-ligatures@0.11.0-beta.198.patch" } } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 95bfd66b0..c2335eb9b 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -7,10 +7,10 @@ settings: patchedDependencies: '@xterm/addon-ligatures@0.11.0-beta.198': hash: df21db050a4d85552cafbe583ece863d7fa19ed634a1219210a0455b986b6634 - path: patches/@xterm__addon-ligatures@0.11.0-beta.198.patch + path: config/patches/@xterm__addon-ligatures@0.11.0-beta.198.patch node-pty@1.1.0: hash: 02e16954edbb8e511963557e3b2c80f8a6fb230cd0c6a75ade936022f3347322 - path: patches/node-pty@1.1.0.patch + path: config/patches/node-pty@1.1.0.patch importers: diff --git a/src/renderer/src/lib/pane-manager/pane-lifecycle.ts b/src/renderer/src/lib/pane-manager/pane-lifecycle.ts index 297fd5e6f..9e8605381 100644 --- a/src/renderer/src/lib/pane-manager/pane-lifecycle.ts +++ b/src/renderer/src/lib/pane-manager/pane-lifecycle.ts @@ -3,7 +3,7 @@ import type { ITerminalOptions } from '@xterm/xterm' import { FitAddon } from '@xterm/addon-fit' // Upstream packaging bug: @xterm/addon-ligatures declares `"main": // "lib/addon-ligatures.js"` but ships only the `.mjs` entry, so Vite fails to -// resolve the bare import. Fixed locally via patches/@xterm__addon-ligatures*. +// resolve the bare import. Fixed locally via config/patches/@xterm__addon-ligatures*. // Tracking upstream: https://github.com/xtermjs/xterm.js/issues/5822 — drop // the patch once that lands. import { LigaturesAddon } from '@xterm/addon-ligatures' diff --git a/vitest.config.ts b/vitest.config.ts deleted file mode 100644 index 614b53e4a..000000000 --- a/vitest.config.ts +++ /dev/null @@ -1,3 +0,0 @@ -import config from './config/vitest.config' - -export default config