Skip to content

Rename the CLI command from zen to avoid clashing with Zen Browser on Linux #126

Closed

Description

@adibhanna

Problem

The opt-in CLI installs a command named zen (apps/desktop/src/main/cli-install.ts symlinks <dir>/zen into ~/.local/bin, ~/bin, or /usr/local/bin). Zen Browser (the popular Firefox fork) also commonly installs a zen command on Linux, so the two collide.

Reported by a user: "zen is also the name of a pretty popular fork of Firefox. That makes your binary directly clash with theirs on Linux, naming-wise."

What actually clashes (and what doesn't)

  • ✅ Desktop app / AUR binary is zennotes (/usr/bin/zennotes from zennotes-bin). No clash here.
  • ⚠️ The CLI is zen — this is the real overlap.

It's a PATH-shadowing collision, not a hard package conflict: ZenNotes' zen lands in ~/.local/bin or /usr/local/bin, Zen Browser's typically in /usr/bin. Different files, so no package-manager error — but since the user dirs usually sit ahead of /usr/bin on $PATH, whichever is first silently wins and zen becomes ambiguous.

Scope / severity

Low-to-moderate. Only affects users who (a) opted into the ZenNotes CLI and (b) run Zen Browser — but that intersection (keyboard-first Linux power users) is exactly our overlap, and Zen Browser is growing. Nothing breaks; it's a confusion/polish issue.

Proposed fix

Rename the CLI command from zen → zn (short, memorable, collision-proof) or zennotes (consistent with the desktop binary). zn preferred. Optionally let the user pick the name at install time, defaulting to zn.

Touch points

  • apps/desktop/src/main/cli-install.ts — the zen symlink name (several path.join(dir, 'zen')) and the wrapper path (path.join(process.resourcesPath, 'zen')).
  • The bundled zen wrapper script in app resources (+ electron-builder extraResources config that ships it).
  • The Install CLI settings UI copy (references zen).
  • Doctor output (prints zen: <version>).
  • Consider keeping zen working as a deprecated alias / migrating existing installs, and uninstall logic (uninstallCli) should clean up the old name.

Activity

  1. added
    enhancement
    on Jun 12, 2026
  2. soulhakr commented on Jun 16, 2026

    @soulhakr

    macOS / Homebrew repro

    This same collision happens on macOS when Zen Browser is installed via Homebrew (brew install --cask zen-browser). Homebrew places a zen binary (or shim) on the PATH, which shadows (or is shadowed by) the ZenNotes CLI symlink depending on PATH ordering.

    So this is not Linux-only — the affected population is broader than the issue title suggests. The fix proposed here (zn or zennotes) would resolve the macOS case as well.

  3. adibhanna commented on Jul 2, 2026

    @adibhanna
    ContributorAuthor

    Shipped in release/v2.10.0 (7c30f05). The opt-in CLI now installs as zn instead of zen, so it no longer collides with Zen Browser's zen on PATH — and since it's the same PATH-shadowing regardless of platform, the macOS/Homebrew case (thanks @soulhakr) is covered too.

    What changed

    • Install symlinks zn. Installing migrates away from a legacy ZenNotes-managed zen, and uninstall sweeps both — but neither ever removes a zen that isn't ours (a foreign zen, e.g. Zen Browser's, is left alone).
    • The bundled wrapper stays zen internally (a resource, never on PATH), so there's no packaging churn.
    • CLI output/help/errors, Settings + command palette, zn mcp, and the Raycast extension (prefers zn, falls back to a legacy zen) all follow.
    • Docs updated in-app and on the website.

    Went with zn (no name-picker) per the issue's preference. Validated by running the built binary (zn --version / --help / errors all read zn) plus tests — the help renders zn and never zen, and the migration removes our own links while sparing a foreign zen and real files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions