From 76e962089aa850014d2294e52af5323da80e01bb Mon Sep 17 00:00:00 2001 From: Steven Syrek Date: Tue, 28 Jul 2026 09:09:00 -0400 Subject: [PATCH] feat(package)!: rename to @deepl/cli and fix stale DeepLcom metadata MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Rename the package to the scoped @deepl/cli for the first npm publish (DeepL owns the @deepl scope; the unscoped names are tombstoned or third-party-held). Add publishConfig.access: "public" — scoped packages default to restricted and the publish fails without it. Point repository/bugs/homepage at github.com/DeepL/deepl-cli instead of relying on the legacy DeepLcom org redirect. The bin name is unchanged: the command is still deepl. The version bump to 2.0.0 is deliberately deferred to the release commit. BREAKING CHANGE: the install string is now `npm install -g @deepl/cli`. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- CHANGELOG.md | 1 + package-lock.json | 4 ++-- package.json | 11 +++++++---- tests/unit/package-manifest.test.ts | 25 +++++++++++++++++++++++++ 4 files changed, 35 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bcaa2dc..c8471ec 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- **BREAKING — package**: The package is now published as the scoped **`@deepl/cli`** (previously the unpublished working name `deepl-cli`). Scoped packages default to restricted visibility, so `publishConfig.access: "public"` is set explicitly — without it the publish fails. The `bin` name is unchanged: the command is still `deepl`, and scoping changes only the install string (`npm install -g @deepl/cli`). Repository, bugs, and homepage metadata now point at `github.com/DeepL/deepl-cli` directly instead of relying on the redirect from the legacy `DeepLcom` org name. - **BREAKING — cache/runtime**: The translation cache now uses Node's built-in `node:sqlite` module instead of the `better-sqlite3` native addon, and the CLI consequently requires **Node.js >= 24** (`engines.node` is now `>=24.0.0`). Node 24 is the first release where `node:sqlite` is non-experimental; Node 18/20 lack the module entirely and Node 22 would both warn on every invocation and downgrade the bundled SQLite (3.50.4 vs 3.53.1). Existing cache databases are read in place with no migration — the on-disk format is unchanged (SQLite 3.53.2-written files verified readable, WAL mode and `user_version` stamp included). **Migration**: upgrade to Node 24 (current LTS), e.g. `nvm install 24`; no other action is needed, and the cache keeps its contents. - **ci**: `.nvmrc` now pins Node 24, matching the CI matrix. It still read `20`, so `nvm use` handed local developers a runtime that cannot load `node:sqlite` and does not satisfy `commander`'s `engines.node >=22.12.0`. diff --git a/package-lock.json b/package-lock.json index 9699b41..5aa3612 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,11 +1,11 @@ { - "name": "deepl-cli", + "name": "@deepl/cli", "version": "1.2.0", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "deepl-cli", + "name": "@deepl/cli", "version": "1.2.0", "license": "MIT", "dependencies": { diff --git a/package.json b/package.json index 464940b..f9f6443 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,9 @@ { - "name": "deepl-cli", + "name": "@deepl/cli", "version": "1.2.0", + "publishConfig": { + "access": "public" + }, "description": "Next-generation CLI for DeepL translation and writing enhancement", "type": "module", "main": "dist/index.js", @@ -99,10 +102,10 @@ }, "repository": { "type": "git", - "url": "https://github.com/DeepLcom/deepl-cli" + "url": "https://github.com/DeepL/deepl-cli" }, "bugs": { - "url": "https://github.com/DeepLcom/deepl-cli/issues" + "url": "https://github.com/DeepL/deepl-cli/issues" }, - "homepage": "https://github.com/DeepLcom/deepl-cli#readme" + "homepage": "https://github.com/DeepL/deepl-cli#readme" } diff --git a/tests/unit/package-manifest.test.ts b/tests/unit/package-manifest.test.ts index 32a9ed4..8a6f453 100644 --- a/tests/unit/package-manifest.test.ts +++ b/tests/unit/package-manifest.test.ts @@ -10,6 +10,11 @@ import * as fs from 'fs'; import * as path from 'path'; interface PackageManifest { + name: string; + publishConfig?: { access?: string }; + repository: { type: string; url: string }; + bugs: { url: string }; + homepage: string; scripts: { clean?: string; build: string; @@ -68,4 +73,24 @@ describe('package.json manifest', () => { expect(Object.values(pkg.bin).every((target) => target.startsWith('dist/'))).toBe(true); }); }); + + describe('publish identity', () => { + it('should be the scoped @deepl/cli package', () => { + expect(pkg.name).toBe('@deepl/cli'); + }); + + it('should keep the bin name deepl regardless of the package scope', () => { + expect(Object.keys(pkg.bin)).toEqual(['deepl']); + }); + + it('should publish publicly — scoped packages default to restricted', () => { + expect(pkg.publishConfig?.access).toBe('public'); + }); + + it('should point repository metadata at the DeepL org, not the legacy DeepLcom redirect', () => { + expect(pkg.repository.url).toBe('https://github.com/DeepL/deepl-cli'); + expect(pkg.bugs.url).toBe('https://github.com/DeepL/deepl-cli/issues'); + expect(pkg.homepage).toBe('https://github.com/DeepL/deepl-cli#readme'); + }); + }); });