Skip to content

Ship README and LICENSE in the npm packages - #135

Merged
PaulAsjes merged 1 commit into
mainfrom
fix/npm-package-readme
Aug 28, 2026
Merged

Ship README and LICENSE in the npm packages#135
PaulAsjes merged 1 commit into
mainfrom
fix/npm-package-readme

Conversation

@PaulAsjes

Copy link
Copy Markdown
Collaborator

The 1.1.0 launcher tarball published yesterday contains exactly two files:

package/bin/cli.js
package/package.json

No README, so npmjs.com/package/@elevenlabs/cli renders a blank page, and no LICENSE, so npm reports all six packages as unlicensed. The files array is ["bin/"], and the platform packages have the same gap.

This carried over from the generated workflow — worth reporting upstream, since any CLI built with the Fern generator will publish blank npm pages.

Changes

Launcher — copies the repository README.md and LICENSE from the tagged checkout, so the page users land on shows the CLI documentation.

Platform packages — take LICENSE from the archive the job already downloads and attestation-verifies, located with the same find -type f -name lookup used for the binary rather than an assumed path, and skipped if absent. They get a short generated README saying not to install them directly; the full CLI README would be misleading on a package nobody should install by hand.

No files change: npm always ships README and LICENSE regardless of that array. Verified by packing a fixture with files: ["bin/"] — both were included, an unrelated file was not.

Testing

Simulated both steps against the real v1.1.0 release archives.

Platform package, from the .tar.gz:

1.1kB   LICENSE       (from the archive)
250B    README.md     (generated)
18.5MB  elevenlabs
80B     package.json

The .zip layout was checked separately, since it holds its files at the archive root rather than inside elevenlabs-cli-<target>/find locates both LICENSE and elevenlabs.exe correctly there.

Launcher:

1.1kB   LICENSE
13.4kB  README.md
15B     bin/cli.js
98B     package.json

The generated README renders correctly, with the escaped backticks and link surviving the heredoc.

Not fixed here

1.1.0 cannot be repaired — npm versions are immutable and the README lives in the tarball. The page stays blank until 1.2.0, which is the deliberate choice: publishing an npm-only 1.1.1 would put npm a patch ahead of Homebrew and Scoop again.

The published 1.1.0 launcher tarball contains only bin/cli.js and
package.json, so npmjs.com renders a blank page for @elevenlabs/cli and
reports all six packages as unlicensed.

The launcher takes the repository README and LICENSE from the tagged
checkout. Platform packages take LICENSE from the archive they already
download and verify, and get a short README saying not to install them
directly — the full CLI README would be misleading on a package users
are not meant to install.

npm ships README and LICENSE regardless of the files array, so no files
change is needed.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@PaulAsjes
PaulAsjes requested a review from kraenhansen August 27, 2026 19:22
@PaulAsjes
PaulAsjes enabled auto-merge (squash) August 27, 2026 19:22

@kraenhansen kraenhansen left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a thought - nothing blocking 👍

Comment thread .github/workflows/ci.yml
# empty and npm reports the package as unlicensed.
LICENSE_SRC=$(find extract -type f -name LICENSE -print -quit)
if [[ -n "${LICENSE_SRC}" ]]; then
install -m 0644 "${LICENSE_SRC}" "${PKG_DIR}/LICENSE"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Used Linux as primary OS for many years and I've never used the install command (https://manpages.ubuntu.com/manpages/jammy/man1/install.1.html) - seems valuable when copying the binary above as its able to set the +x flag in a single invocation, but here it's kind of weird to not simply use a cp 🤔

@PaulAsjes
PaulAsjes merged commit 7c5a4d2 into main Aug 28, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants