diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 70ca5a3..f4e4f8f 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -21,7 +21,7 @@ A clear and concise description of what you expected to happen. **Environment:** - OS: [e.g. CachyOS, Arch Linux, macOS 15] -- Bun version: [e.g. 1.4.0] +- Bun version: [e.g. 1.4.4] - Commit: [e.g. commit SHA] **Additional context** diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 15a7007..931dea4 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -60,7 +60,7 @@ jobs: - name: Set up Bun uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2 with: - bun-version: 1.4.2 + bun-version: 1.4.4 - name: Install dependencies run: bun install --frozen-lockfile diff --git a/.github/workflows/plugin-integration.yml b/.github/workflows/plugin-integration.yml index c2d2aca..261f515 100644 --- a/.github/workflows/plugin-integration.yml +++ b/.github/workflows/plugin-integration.yml @@ -35,7 +35,7 @@ jobs: - name: Set up Bun uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2 with: - bun-version: 1.4.2 + bun-version: 1.4.4 - name: Install dependencies run: bun install --frozen-lockfile - name: Install Lua 5.4 (official plugin runtime baseline) diff --git a/.github/workflows/registry-check.yml b/.github/workflows/registry-check.yml index 58c3e25..7f8ed8b 100644 --- a/.github/workflows/registry-check.yml +++ b/.github/workflows/registry-check.yml @@ -47,7 +47,7 @@ jobs: - name: Set up Bun uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2 with: - bun-version: 1.4.2 + bun-version: 1.4.4 - name: Install dependencies run: bun install --frozen-lockfile - name: Validate registry diff --git a/.markdownlint-cli2.jsonc b/.markdownlint-cli2.jsonc deleted file mode 100644 index b3f9129..0000000 --- a/.markdownlint-cli2.jsonc +++ /dev/null @@ -1,20 +0,0 @@ -{ - "config": { - "default": true, - "MD013": false, - "MD024": { "siblings_only": true }, - "MD033": false, - "MD041": false, - }, - "globs": ["**/*.md"], - "ignores": [ - "**/node_modules/**", - ".worktrees", - "dist", - "sdk", - "template", - "plugins", - "docs", - "recording", - ], -} diff --git a/.prettierignore b/.prettierignore deleted file mode 100644 index 70a65bb..0000000 --- a/.prettierignore +++ /dev/null @@ -1,12 +0,0 @@ -node_modules/ -sdk/ -template/ -plugins/ -docs/ -app/dist/ -.wrangler/ -.worktrees/ -bun.lock - -# Generated artifact: canonical formatting is owned by scripts/generate-index.ts. -generated/ diff --git a/app/package.json b/app/package.json index bbcc58a..94a3322 100644 --- a/app/package.json +++ b/app/package.json @@ -9,11 +9,10 @@ "dev": "vite", "build": "vite build", "preview": "vite preview", - "type-check": "tsc -p tsconfig.json --noEmit" + "type-check": "bun check --no-script -p tsconfig.json" }, "devDependencies": { "@types/node": "26.5.1", - "typescript": "5.7.2", "vite": "8.3.0" } } diff --git a/bun.lock b/bun.lock index ab67cb3..8705cd9 100644 --- a/bun.lock +++ b/bun.lock @@ -5,11 +5,8 @@ "": { "name": "bitty-plugins", "devDependencies": { - "@commitlint/config-conventional": "21.2.2", - "@types/bun": "1.2.0", - "bun-types": "1.2.0", - "carryctx": "0.11.5", - "typescript": "5.7.2", + "@types/bun": "1.4.4", + "carryctx": "0.11.6", }, }, "app": { @@ -17,18 +14,11 @@ "version": "0.0.0", "devDependencies": { "@types/node": "26.5.1", - "typescript": "5.7.2", "vite": "8.3.0", }, }, }, "packages": { - "@commitlint/config-conventional": ["@commitlint/config-conventional@21.2.2", "", { "dependencies": { "@commitlint/types": "^21.2.0", "conventional-changelog-conventionalcommits": "^10.0.0" } }, "sha512-NxA37SZviusFUEYOQZ5hNnZ1h7O/KiemPkxjOlpzKJNnWxThiwc6/SaZhaPa8fyLvfRBAywhQhJJk8XESHWlpQ=="], - - "@commitlint/types": ["@commitlint/types@21.2.0", "", { "dependencies": { "conventional-commits-parser": "^7.0.0", "picocolors": "^1.1.1" } }, "sha512-7zVFCDB2reMvJH5dmbKnOQPjZEvjdJTH8jc0U/PIPU1r3/+vf5pD1HlfitV2MWsWXrvu7u39iY1lyLUPOaN0Gw=="], - - "@conventional-changelog/template": ["@conventional-changelog/template@1.4.0", "", {}, "sha512-aalGyl7dbB5PArRebDIX43ZvBlXrYm9uWzGJ26t+4SzJVPsOuvfILGGbw5X4yX7i50YEmJ8zvbiWnqH/AAnZqg=="], - "@oxc-project/types": ["@oxc-project/types@0.149.0", "", {}, "sha512-Efcc+iF0j3Bf67YjEqIqWXbX5XddXoK/Mw4K1/JuXwRCZ8N16VR7iT23nlCc9XrveFVh/E5Rqs2StT0V8v9LdA=="], "@rolldown/binding-android-arm-eabi": ["@rolldown/binding-android-arm-eabi@1.2.8", "", { "os": "android", "cpu": "arm" }, "sha512-tN5aztYkKCte4i5SIrrz5yK/HMjEuCqCSCJa418jOV8tZ1cBY3YF2otxB1ktPxzsLA1BeTqwapK0bfjxNvHJVw=="], @@ -63,35 +53,25 @@ "@rolldown/pluginutils": ["@rolldown/pluginutils@1.0.1", "", {}, "sha512-2j9bGt5Jh8hj+vPtgzPtl72j0yRxHAyumoo6TNfAjsLB04UtpSvPbPcDcBMxz7n+9CYB0c1GxQFxYRg2jimqGw=="], - "@simple-libs/stream-utils": ["@simple-libs/stream-utils@2.0.0", "", {}, "sha512-fCTuZK4QBa+39Oz9l4OGfJfz+GpwCp3AqO7Zch3to99xHPgstVsRFpeQ8LNd2o1Gv8raL2mCFwiaHh7bFSp5DQ=="], - - "@types/bun": ["@types/bun@1.2.0", "", { "dependencies": { "bun-types": "1.2.0" } }, "sha512-5N1JqdahfpBlAv4wy6svEYcd/YfO2GNrbL95JOmFx8nkE6dbK4R0oSE5SpBA4vBRqgrOUAXF8Dpiz+gi7r80SA=="], + "@types/bun": ["@types/bun@1.4.4", "", { "dependencies": { "bun-types": "1.4.4" } }, "sha512-9wkRDXUXK124pEnAutE6n/l18j+i9GC5IAHK8TmX/2nlySETmky0OU6yL5U8pW1AoKh++AN9auDCr647BfurjQ=="], "@types/node": ["@types/node@26.5.1", "", { "dependencies": { "undici-types": "~8.9.0" } }, "sha512-CzNm2FezW4VR/LjG6yUdiEgLE/rAQ9Slj5gCu/C2VrdcW7I0ahNZ8DRbHT7zOZ6r3ONgd/bsQIeSaoDGrd1C6g=="], - "@types/ws": ["@types/ws@8.5.14", "", { "dependencies": { "@types/node": "*" } }, "sha512-bd/YFLW+URhBzMXurx7lWByOu+xzU9+kb3RboOteXYDfW+tr+JZa99OyNmPINEGB/ahzKrEuc8rcv4gnpJmxTw=="], - - "argue-cli": ["argue-cli@3.2.0", "", {}, "sha512-VipTB0gXgGIFO2Rg9yEVN5wLt2AurJcZqDbgmYSwPwsykhLrQhs240/bfceev4w68lI8JshoOJIk9uW7tFzROw=="], - "bitty-plugins-store": ["bitty-plugins-store@workspace:app"], - "bun-types": ["bun-types@1.2.0", "", { "dependencies": { "@types/node": "*", "@types/ws": "~8.5.10" } }, "sha512-KEaJxyZfbV/c4eyG0vyehDpYmBGreNiQbZIqvVHJwZ4BmeuWlNZ7EAzMN2Zcd7ailmS/tGVW0BgYbGf+lGEpWw=="], - - "carryctx": ["carryctx@0.11.5", "", { "optionalDependencies": { "carryctx-cli-darwin-arm64": "0.11.5", "carryctx-cli-darwin-x64": "0.11.5", "carryctx-cli-linux-arm64-gnu": "0.11.5", "carryctx-cli-linux-x64-gnu": "0.11.5", "carryctx-cli-windows-x64": "0.11.5" }, "bin": { "carryctx": "bin/carryctx.js" } }, "sha512-vyrEvXPWPXA2QM4v+gADZt9m9lTkgYXt9nCH5N/H06n7TinhQv9EadlQ4jSUcPv8Z1RlVmi2AOCWrMJoOfeuBw=="], + "bun-types": ["bun-types@1.4.4", "", { "dependencies": { "@types/node": "*", "undici-types": "*" } }, "sha512-yjrJh5oGX7mMPKGd19YXyIjmEuj4G4zNC30bs7PM9Az7NQ3ndF3j6hbeRdvJTRQEhJ/FYQwW0a2moweEi2hMxQ=="], - "carryctx-cli-darwin-arm64": ["carryctx-cli-darwin-arm64@0.11.5", "", { "os": "darwin", "cpu": "arm64" }, "sha512-WGopxz7Vk5lUNYx+hrwbBLEw3T2CenmuoYAuAPHqRLiwfd+j02fS6YzpbBaDm3QrZc5xnhkwWFASI1YBPRYprg=="], + "carryctx": ["carryctx@0.11.6", "", { "optionalDependencies": { "carryctx-cli-darwin-arm64": "0.11.6", "carryctx-cli-darwin-x64": "0.11.6", "carryctx-cli-linux-arm64-gnu": "0.11.6", "carryctx-cli-linux-x64-gnu": "0.11.6", "carryctx-cli-windows-x64": "0.11.6" }, "bin": { "carryctx": "bin/carryctx.js" } }, "sha512-dugNgLJZYIdkHKDQUzcrrdOX9zjcBAg070CsHLMXw8uBIJ07dl4hfz7bGGYt8WnCJCp1OPAlXqVUUzOBweUNRg=="], - "carryctx-cli-darwin-x64": ["carryctx-cli-darwin-x64@0.11.5", "", { "os": "darwin", "cpu": "x64" }, "sha512-1B0xXRS+7MWxMtorsWejkjtj41/TFbdbkrL3Gnuat9sW9qNwaBlLoI9dyTkdABF8Bb30Vkw5RjDRvLE+vsRdEw=="], + "carryctx-cli-darwin-arm64": ["carryctx-cli-darwin-arm64@0.11.6", "", { "os": "darwin", "cpu": "arm64" }, "sha512-JSkDoYne98SKAcrTIoZqodXAzmn8getqG25xx9yf5m6kGkXkayrOfvDpgfhxHsLknC+tAX7IYzLcNx5hjRNXqA=="], - "carryctx-cli-linux-arm64-gnu": ["carryctx-cli-linux-arm64-gnu@0.11.5", "", { "os": "linux", "cpu": "arm64" }, "sha512-GSR1u7b/Hab9+s92N+O1c6r4d94qdavlgdmpCmT8nahXLIMiqUy8XY5BDg17HfJxK1DteVvWu4MIMlw2H2Nc3w=="], + "carryctx-cli-darwin-x64": ["carryctx-cli-darwin-x64@0.11.6", "", { "os": "darwin", "cpu": "x64" }, "sha512-A6Xogh4Q5T/Ns/uQqKxc3KUqzlSGD2xAVGlfA6M7xicRaxH52PJZjGvxAZpjnI3LIlKXiqwoiJa54TXvuL4pjQ=="], - "carryctx-cli-linux-x64-gnu": ["carryctx-cli-linux-x64-gnu@0.11.5", "", { "os": "linux", "cpu": "x64" }, "sha512-fDR0PU0MWUwQ7eOlowhGjIViGuAiPGuyxD74OvR136qAQ54a/r8FUCun4hiPMfCoWmPpZr3hQ6McOsTE93Wh+A=="], + "carryctx-cli-linux-arm64-gnu": ["carryctx-cli-linux-arm64-gnu@0.11.6", "", { "os": "linux", "cpu": "arm64", "libc": "glibc" }, "sha512-IvOGo2miAuJQUo06CjsL8VHn8K1IrGIpjcCh2dLfzDTVarxm1O91URYDJzWIpp8M6EDcGip3vx1RG3mG4RDq6A=="], - "carryctx-cli-windows-x64": ["carryctx-cli-windows-x64@0.11.5", "", { "os": "win32", "cpu": "x64" }, "sha512-T0Q1khzH+k/q4rRAPkUwXv9k4bMTdQQTAPJLc8fTSyr+K9qQxPL4qFBt82Z2YvSVXcpD5rWKfuBhD5b5qmzBgw=="], + "carryctx-cli-linux-x64-gnu": ["carryctx-cli-linux-x64-gnu@0.11.6", "", { "os": "linux", "cpu": "x64", "libc": "glibc" }, "sha512-QZ4gOXxDdJGkssIS7N8L1H2jarvvk+HdOuMR/79IuJccV8Lt4YPQhCcouwSlh2l+GMkqICg/LjudVxCj3Q1FtQ=="], - "conventional-changelog-conventionalcommits": ["conventional-changelog-conventionalcommits@10.4.0", "", { "dependencies": { "@conventional-changelog/template": "^1.4.0" } }, "sha512-Rriac6ZrAlVm6cy9Bz4NSp+WMHpwNXoPIYex+HjCgduAVUSbnew29DQjQw0C4g9u3HtSYzGiGY+pdBXAZo+4aA=="], - - "conventional-commits-parser": ["conventional-commits-parser@7.1.2", "", { "dependencies": { "@simple-libs/stream-utils": "^2.0.0", "argue-cli": "^3.1.0" }, "bin": { "conventional-commits-parser": "./dist/cli/index.js" } }, "sha512-O+x4N2yH+ijvqWlIyTHsXTAP+algNWgGbjY2duCe8w2vUMvUB95cLRslCPfTMQyLAKlet3bhZTdu6ozn4M+QJQ=="], + "carryctx-cli-windows-x64": ["carryctx-cli-windows-x64@0.11.6", "", { "os": "win32", "cpu": "x64" }, "sha512-mRCr33aIM4gFOaLGX4fE8f7vEnaOEvJ2uMOpL+M+NtYu3t5sh/bhpiTSJ2lzc7bnpNQTYR8H06KjStljUJtoCQ=="], "detect-libc": ["detect-libc@2.1.2", "", {}, "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ=="], @@ -137,8 +117,6 @@ "tinyglobby": ["tinyglobby@0.2.17", "", { "dependencies": { "fdir": "^6.5.0", "picomatch": "^4.0.4" } }, "sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g=="], - "typescript": ["typescript@5.7.2", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-i5t66RHxDvVN40HfDd1PsEThGNnlMCMT3jMUuoh9/0TaqWevNontacunWyN02LA9/fIbEWlcHZcgTKb9QoaLfg=="], - "undici-types": ["undici-types@8.9.0", "", {}, "sha512-KTDyRTYX8sWmKXAikPHHSyc63CRPETMctyjKFupcC6OBLXT3xsN0e9aF7m+mIXutFWpUXuedtowG7iLOzp0kQg=="], "vite": ["vite@8.3.0", "", { "dependencies": { "lightningcss": "^1.33.0", "picomatch": "^4.0.7", "postcss": "^8.5.28", "rolldown": "~1.2.6", "tinyglobby": "^0.2.17" }, "optionalDependencies": { "fsevents": "~2.3.3" }, "peerDependencies": { "@types/node": "^20.19.0 || >=22.12.0", "@vitejs/devtools": "^0.7.1", "esbuild": "^0.27.0 || ^0.28.0", "jiti": ">=1.21.0", "less": "^4.0.0", "sass": "^1.70.0", "sass-embedded": "^1.70.0", "stylus": ">=0.54.8", "sugarss": "^5.0.0", "terser": "^5.16.0", "tsx": "^4.8.1", "yaml": "^2.4.2" }, "optionalPeers": ["@types/node", "@vitejs/devtools", "esbuild", "jiti", "less", "sass", "sass-embedded", "stylus", "sugarss", "terser", "tsx", "yaml"], "bin": { "vite": "bin/vite.js" } }, "sha512-lhZBVvEHefgE+HQZC9O7EBJgCU/nVzFNl7vkS4RE0APtWLP02/8QVIkQtzBxPquh7lq5/78NHipTj7ODQ6XuyQ=="], diff --git a/commitlint.config.ts b/commitlint.config.ts deleted file mode 100644 index f055add..0000000 --- a/commitlint.config.ts +++ /dev/null @@ -1,11 +0,0 @@ -export default { - extends: ["@commitlint/config-conventional"], - // CarryCtx's prepare-commit-msg hook prefixes subjects with the owning task, - // for example "[CTX-0001] feat(registry): ..."; accept and ignore that prefix. - parserPreset: { - parserOpts: { - headerPattern: /^(?:\[CTX-\d+\]\s+)?(\w*)(?:\((.*)\))?!?: (.*)$/, - headerCorrespondence: ["type", "scope", "subject"], - }, - }, -}; diff --git a/justfile b/justfile index 96352c3..2b989d8 100644 --- a/justfile +++ b/justfile @@ -1,43 +1,29 @@ # Bitty Plugins quality gates. # -# Tool version pins live here (one place); installed dev dependencies are -# pinned in package.json + bun.lock. All JavaScript tooling runs through -# bun / bunx; never use npm, npx, or yarn, and never invoke formatters or -# linters directly by name. - -markdownlint_pin := "0.23.1" -prettier_pin := "3.9.6" -commitlint_pin := "21.2.2" -lefthook_pin := "2.1.10" +# All JavaScript and TypeScript gates run natively through Bun 1.4.4 (`bun fmt`, +# `bun check`, `bun test`). + wrangler_pin := "4.125.0" # List available recipes. default: @just --list -# Lint all Markdown sources against .markdownlint-cli2.jsonc. -lint: - bunx --bun markdownlint-cli2@{{markdownlint_pin}} - -# Lint specific Markdown files (used by the pre-commit hook). -lint-files *files: - bunx --bun markdownlint-cli2@{{markdownlint_pin}} {{files}} - -# Format all recognized files with Prettier. +# Format all recognized files with Bun's native formatter. fmt: - bunx --bun prettier@{{prettier_pin}} --write . --ignore-unknown + bun fmt --no-script --no-config --ignore-unknown --ignore-pattern="generated/**" --ignore-pattern="sdk/**" --ignore-pattern="template/**" -# Check formatting of all recognized files with Prettier. +# Check formatting of all recognized files with Bun's native formatter. fmt-check: - bunx --bun prettier@{{prettier_pin}} --check . --ignore-unknown + bun fmt --no-script --no-config --check --ignore-unknown --ignore-pattern="generated/**" --ignore-pattern="sdk/**" --ignore-pattern="template/**" # Check formatting of specific files (used by the pre-commit hook). fmt-check-files *files: - bunx --bun prettier@{{prettier_pin}} --check {{files}} + bun fmt --no-script --no-config --check --ignore-unknown --ignore-pattern="generated/**" --ignore-pattern="sdk/**" --ignore-pattern="template/**" {{files}} -# Type-check scripts/ and app/ with the TypeScript pinned in package.json. +# Type-check scripts/ and app/ with Bun's native TypeScript checker. type-check: - bunx --bun tsc -p tsconfig.json --noEmit + bun check --no-script -p tsconfig.json cd app && bun run type-check # Run this repository's registry and tooling test suite (tests/ only; @@ -85,18 +71,10 @@ app-dev: app-preview: app-build cd app && bun run preview -# Validate a commit message file with commitlint (conventional commits). -commit-check message=".git/COMMIT_EDITMSG": - test -d node_modules/@commitlint/config-conventional || bun install --frozen-lockfile - bunx --bun commitlint@{{commitlint_pin}} --edit "{{message}}" - -# Install Git hooks managed by lefthook (opt-in per contributor checkout). +# Install Git hooks managed by lefthook and CarryCtx. hooks-install: - bunx --bun lefthook@{{lefthook_pin}} install - -# Remove lefthook-managed Git hooks. -hooks-uninstall: - bunx --bun lefthook@{{lefthook_pin}} uninstall + bun run lefthook install pre-commit + bun run carryctx hooks install --compose # Lint GitHub Actions workflows with the locally installed actionlint. # CI runs the same version as rhysd/actionlint:1.7.12 in a container. @@ -160,7 +138,7 @@ integration-smoke: exit "$status" # Aggregate read-only gate run locally and in CI. -check: fmt-check lint type-check test registry-validate registry-check catalog-validate app-build +check: fmt-check type-check test registry-validate registry-check catalog-validate app-build # Deploy the built store to Cloudflare Pages. Requires CLOUDFLARE_API_TOKEN and # CLOUDFLARE_ACCOUNT_ID and a provisioned Pages project; dormant until then. diff --git a/lefthook.yml b/lefthook.yml index 7840a69..d60dbc6 100644 --- a/lefthook.yml +++ b/lefthook.yml @@ -1,16 +1,5 @@ -# Git hooks managed by lefthook. Install with `just hooks-install`. -# All tool pins live in the justfile; this file only wires hooks to it. - -commit-msg: - commands: - commit-check: - run: just commit-check {1} - +# Lefthook owns pre-commit; CarryCtx owns prepare-commit-msg and post-commit. pre-commit: commands: - markdownlint-staged: - glob: "*.md" - run: just lint-files {staged_files} - prettier-staged: - glob: "*.md" + format-check: run: just fmt-check-files {staged_files} diff --git a/package.json b/package.json index c4a5fb5..0ea2af8 100644 --- a/package.json +++ b/package.json @@ -8,16 +8,13 @@ ], "description": "Official plugin directory, registry, and store frontend for the Bitty ecosystem.", "license": "MIT", - "packageManager": "bun@1.4.2", + "packageManager": "bun@1.4.4", "scripts": { - "type-check": "tsc -p tsconfig.json --noEmit", + "type-check": "bun check --no-script -p tsconfig.json", "test": "bun test" }, "devDependencies": { - "@commitlint/config-conventional": "21.2.2", - "@types/bun": "1.2.0", - "bun-types": "1.2.0", - "carryctx": "0.11.5", - "typescript": "5.7.2" + "@types/bun": "1.4.4", + "carryctx": "0.11.6" } } diff --git a/sdk b/sdk index c4f27d3..ecf8292 160000 --- a/sdk +++ b/sdk @@ -1 +1 @@ -Subproject commit c4f27d3dff0743a1f93c367995e0d244422c7504 +Subproject commit ecf8292a654b92ab396d00bbf59660ba298cf2c3 diff --git a/tsconfig.json b/tsconfig.json index 10a6a9a..d93a063 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -4,7 +4,7 @@ "module": "ESNext", "moduleResolution": "Bundler", "lib": ["ES2022"], - "types": ["bun-types"], + "types": ["bun"], "strict": true, "noUncheckedIndexedAccess": true, "exactOptionalPropertyTypes": false,