# Install nb with Homebrew, apk, MacPorts, Nix

Command-line and local web note-taking, bookmarking, and archiving. Version 7.25.4 via Homebrew; verified 2026-06-14.

## Install

```sh
sudo av install brew:nb
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install nb
```

  Evidence: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install nb
```

  Evidence: MacPorts ports tree: office/nb/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add nb
```

  Evidence: Alpine Linux edge package indexes: nb from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz

- Nix (92%):

```sh
nix profile install nixpkgs#nb
```

  Evidence: nixpkgs package indexes: pkgs/by-name/nb/nb/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

## Package facts

- **Package key:** brew:nb
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/nb>
- **Version:** 7.25.4
- **Source summary:** Command-line and local web note-taking, bookmarking, and archiving
- **Homepage:** <https://xwmx.github.io/nb>
- **Repository:** <https://github.com/xwmx/nb>
- **Upstream docs:** <https://github.com/xwmx/nb#readme>
- **License:** AGPL-3.0-or-later
- **Source archive:** <https://github.com/xwmx/nb/archive/refs/tags/7.25.4.tar.gz>
- **Last updated:** 2026-06-14T05:08:25Z
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- bookmark (cli)
- nb (cli)
- bookmark (alias)
- nb (alias)

## Dependencies

- bat
- nmap
- pandoc
- ripgrep
- tig
- w3m

## Install behavior

- Post-install hook: not defined
- Bottle: available on all

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 7.25.4
- Package-manager updated: 2026-06-14
- Local data: ok
- Upstream repository: https://github.com/xwmx/nb
- Upstream latest detected: 7.25.4 (current)
## Project history and usage

nb is a shell-script personal knowledge tool: notes, bookmarks, archives, todos, wiki-style links, search, encryption, Git-backed version history, and sync wrapped in one command-line and local-web interface.

### Project history

The GitHub repository was created on 2016-01-12. The project presents itself as a portable, vendor-independent Unix tool rather than a hosted notes service: data lives in plain text formats such as Markdown, Org, LaTeX, and AsciiDoc, and the implementation is deliberately packaged as a single portable script with optional enhancements.

Its design grew around composability with existing command-line habits. The README emphasizes use with Vim, Emacs, VS Code, Sublime Text, Helix, micro, terminal browsers, GUI browsers, Git, Pandoc, OpenSSL/GPG encryption, and standard Unix environments including macOS and Windows via WSL, MSYS, and Cygwin.

### Adoption history

GitHub API data retrieved on 2026-07-01 showed 8,266 stars and 252 forks. Homebrew Formulae data for the same retrieval showed version 7.25.4 and 2,815 installs over the prior 365 days. The npm package nb.sh was created on 2020-06-17 and the npm downloads API reported 1,450 downloads for 2026-05-30 through 2026-06-28.

The package sits in the command-line PKM and plain-text productivity niche: large enough to be packaged by common package managers and discussed by terminal-tool users, but still most useful to people who already want their notes and bookmarks as files rather than SaaS records.

### How it is used

Package nerds use nb as a local-first notebook and bookmark database: add notes from the terminal, save URLs as cleaned Markdown, search cached page text with regular expressions, tag and pin items, and let Git record revisions and synchronize notebooks.

A typical setup is intentionally boring: install nb, keep ~/.nbrc for preferences, point it at an editor, and optionally add Pandoc, ripgrep/ag/grep, browser helpers, GPG/OpenSSL, and remote Git sync as the workflow grows.

### Why package nerds care

nb is interesting because it is not a new storage backend. It packages a familiar Unix stack into a cohesive notes/bookmarks/archive workflow while keeping the escape hatch obvious: the data remains ordinary files under Git.

### Timeline

- 2016-01-12: xwmx/nb repository created on GitHub.
- 2020-06-17: nb.sh package created on npm.
- 2026-04-28: nb 7.25.4 release published on GitHub.
- 2026-07-01: Homebrew Formulae reported stable version 7.25.4.

### Sources

- <https://api.github.com/repos/xwmx/nb>
- <https://api.npmjs.org/downloads/point/last-month/nb.sh>
- <https://formulae.brew.sh/api/formula/nb.json>
- <https://github.com/xwmx/nb>
- <https://raw.githubusercontent.com/xwmx/nb/master/README.md>
- <https://registry.npmjs.org/nb.sh>


## Security Notes

narrow executable package without higher-risk signals.

- **Geiger risk:** green / low
- narrow executable package without higher-risk signals


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: ~/.nbrc
## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** nb
- **Version Scheme:** 0
- **Revision:** 0
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable

## Other Package-Manager Records

- Nix - nb: normalized package name match | nixpkgs package indexes: pkgs/by-name/nb/nb/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- apk - nb - 7.24.1-r0: normalized package name match | Alpine Linux edge package indexes: nb from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Command line note-taking, bookmarking, archiving, and knowledge base application | https://github.com/xwmx/nb
- apk - nb-bash-completion - 7.24.1-r0: normalized package name match | Alpine Linux edge package indexes: nb-bash-completion from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Bash completions for nb | https://github.com/xwmx/nb
- apk - nb-doc - 7.24.1-r0: normalized package name match | Alpine Linux edge package indexes: nb-doc from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Command line note-taking, bookmarking, archiving, and knowledge base application (documentation) | https://github.com/xwmx/nb
- apk - nb-fish-completion - 7.24.1-r0: normalized package name match | Alpine Linux edge package indexes: nb-fish-completion from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Fish completions for nb | https://github.com/xwmx/nb
- apk - nb-full - 7.24.1-r0: normalized package name match | Alpine Linux edge package indexes: nb-full from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | More utilities that integrate with nb | https://github.com/xwmx/nb
- apk - nb-zsh-completion - 7.24.1-r0: normalized package name match | Alpine Linux edge package indexes: nb-zsh-completion from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Zsh completions for nb | https://github.com/xwmx/nb
- MacPorts - nb: normalized package name match | MacPorts ports tree: office/nb/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## Related links

- [Source-control packages](https://www.automicvault.com/pkg/source-control-tools/) - Belongs to a source-control command family.
- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Networking and protocol packages](https://www.automicvault.com/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [Web development packages](https://www.automicvault.com/pkg/web-dev-tools/) - Matched web development metadata.
- [bat](https://www.automicvault.com/pkg/brew/bat/) - Runtime dependency declared by Homebrew.
- [nmap](https://www.automicvault.com/pkg/brew/nmap/) - Runtime dependency declared by Homebrew.
- [pandoc](https://www.automicvault.com/pkg/brew/pandoc/) - Runtime dependency declared by Homebrew.
- [ripgrep](https://www.automicvault.com/pkg/brew/ripgrep/) - Runtime dependency declared by Homebrew.
- [tig](https://www.automicvault.com/pkg/brew/tig/) - Runtime dependency declared by Homebrew.
- [w3m](https://www.automicvault.com/pkg/brew/w3m/) - Runtime dependency declared by Homebrew.
- [cherrytree](https://www.automicvault.com/pkg/brew/cherrytree/) - Shares av.db curated category or tags: cli, notes, productivity.
- [dnote](https://www.automicvault.com/pkg/brew/dnote/) - Shares av.db curated category or tags: cli, notes, productivity.
- [ekphos](https://www.automicvault.com/pkg/brew/ekphos/) - Shares av.db curated category or tags: cli, notes, productivity.
- [eureka](https://www.automicvault.com/pkg/brew/eureka/) - Shares av.db curated category or tags: cli, notes, productivity.
- [evernote-backup](https://www.automicvault.com/pkg/brew/evernote-backup/) - Shares av.db curated category or tags: cli, notes, productivity.
- [joplin-cli](https://www.automicvault.com/pkg/brew/joplin-cli/) - Shares av.db curated category or tags: cli, notes, productivity.
- [jot](https://www.automicvault.com/pkg/brew/jot/) - Shares av.db curated category or tags: cli, notes, productivity.
- [jrnl](https://www.automicvault.com/pkg/brew/jrnl/) - Shares av.db curated category or tags: cli, notes, productivity.
- [buku](https://www.automicvault.com/pkg/brew/buku/) - Local package facts share a topical domain. Shared terms: bookmark, bookmarks, cli, command-line, line.

## Combined YAML source

View the package source record on GitHub. [combined/nb.yml](https://github.com/automic-vault/db/blob/main/combined/nb.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated configuration and credential file locations
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
