Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/xwmx/nb/llms.txt

Use this file to discover all available pages before exploring further.

nb is a single portable Bash script with minimal requirements. You can install it through a package manager for the most convenient experience, or download it directly when a package manager is not available. On every platform the result is the same: one executable, ready to run.

Dependencies

Required

Before installing nb, make sure the following are available on your system:
  • Bashnb is a Bash script. It works perfectly with Zsh, Fish, and any other shell as your primary login shell; the system just needs Bash available.
  • Git — used for automatic versioning and sync.
  • A text editor with command-line support, such as Vim, Emacs, Visual Studio Code, Sublime Text, Helix, micro, nano, or any other editor you prefer.

Optional

nb checks the environment for additional tools and uses them to enhance the experience whenever they are available. None of these are required for core functionality. Recommended optional dependencies:
ToolWhat it enables
batSyntax-highlighted note previews
ncat or socatLocal web browsing interface (nb browse)
pandocFormat conversion, Markdown rendering of bookmarked pages
rg (ripgrep)Faster full-text search
tigVisual Git history browsing
w3mTerminal web browser for nb browse
On Ubuntu and WSL, run sudo nb env install after installing nb to automatically install the recommended optional dependencies.
Also supported for various enhancements: Ack, afplay, asciidoctor, The Silver Searcher (ag), catimg, Chafa, Chromium/Chrome, eza, ffplay, ImageMagick, glow, GnuPG, highlight, imgcat, joshuto, kitty’s icat kitten, lowdown, lsd, Links, Lynx, mdcat, mdless, mdv, Midnight Commander (mc), mpg123, MPlayer, netcat, pdftotext, Pygments, Ranger, readability-cli, rga/ripgrep-all, sc-im, termvisage, termpdf.py, Tidy-Viewer (tv), timg, vifm, viu, VisiData.

Installation Methods

Installing via Homebrew is the recommended method on macOS. It automatically installs the recommended optional dependencies and sets up tab completion for Bash, Zsh, and Fish.
brew install xwmx/taps/nb
nb is also available in homebrew-core. Installing it alongside the bash formula is recommended:
brew install nb bash
To install the latest development version directly from the repository:
brew install xwmx/taps/nb --head

Tab Completion

Bash, Fish, and Zsh tab completion is enabled automatically when nb is installed via Homebrew, npm (with the completions install step), make, or the curl/wget commands shown above. If completion is not working after installation, run:
sudo nb completions install
Or install both completions and optional dependencies together:
sudo nb env install
For manual setup instructions, see the completion installation guide.

Updating

Use the package manager’s standard upgrade command:
# Homebrew
brew upgrade nb

# npm
npm update -g nb.sh

Build docs developers (and LLMs) love