macOS
brew install nilocal Homebrew formula metadata
安装
brew install nilocal Homebrew formula metadata
nix profile install nixpkgs#ninixpkgs package indexes · pkgs/by-name/ni/ni/package.nix · 来源: api.github.com
概览
Selects the right Node package manager based on lockfiles
历史
`ni` is Anthony Fu's JavaScript package-manager dispatcher: one set of short commands that detects whether a project uses npm, Yarn, pnpm, Bun, or Deno and runs the matching package-manager command.
The npm registry metadata for `@antfu/ni` shows the package created on November 5, 2020. The project later moved under the `antfu-collective` GitHub organization while keeping the author ecosystem around Anthony Fu's JavaScript tooling.
The README documents the core idea as lockfile and package metadata detection. It maps `ni`, `nr`, `nlx`, `nup`, `nun`, `nci`, `nd`, and `na` onto equivalent npm, Yarn, pnpm, Bun, and Deno operations, and uses the separate `package-manager-detector` package for detection.
The tool became a small package-nerd convenience in the Node ecosystem because frontend and monorepo developers often switch between repositories with different lockfiles. Homebrew analytics on July 1, 2026 reported 1,661 install-on-request events over 365 days, and the npm package was modified as version 30.2.0 on June 25, 2026.
The ecosystem signal is not that `ni` owns dependency installation, but that it standardizes muscle memory. Its README includes Homebrew and asdf installation paths, auto-install support for missing package managers, and configuration through `~/.nirc` or environment variables.
Practical usage is intentionally tiny: run `ni` to install dependencies, `nr` to run scripts, `nlx` to download and execute a package, `nup` to upgrade, `nun` to uninstall, `nci` for clean/frozen installs, and `na` to invoke the detected package manager itself. The tool detects `yarn.lock`, `pnpm-lock.yaml`, `package-lock.json`, `bun.lock`, `bun.lockb`, `deno.json`, `deno.jsonc`, or the `packageManager` field.
安全态势
infrastructure mutation or orchestration signal.
orange 风险 · 中 置信度 · infrastructure
在无人值守的代理使用前,请检查该工具是否读取明文凭据、写入远程状态、发布制品或调用插件。
local files
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.
Config paths the tool may read or write during local use.
~/.nirc可执行文件
| 命令 | 类型 | 暴露范围 | 备注 |
|---|---|---|---|
na | cli | 全局可执行文件 | |
nci | cli | 全局可执行文件 | |
nd | cli | 全局可执行文件 | |
ni | cli | 全局可执行文件 | |
nlx | cli | 全局可执行文件 | |
nr | cli | 全局可执行文件 | |
nun | cli | 全局可执行文件 | |
nup | cli | 全局可执行文件 |
新鲜度
这些信号区分页生成时间、软件包管理器活动和上游发布比较。只有存在证据 URL 和可比较版本时,才会提示版本落后。
https://github.com/antfu-collective/ni
安装元数据
| 软件包键 | brew:ni |
|---|---|
| 版本 | 30.6.0 |
| 软件包管理器 | Homebrew |
| 软件包管理器页面 | https://formulae.brew.sh/formula/ni |
| 主页 | https://github.com/antfu-collective/ni |
| 仓库 | https://github.com/antfu-collective/ni |
| 许可证 | MIT |
| 源码归档 | https://registry.npmjs.org/@antfu/ni/-/ni-30.5.0.tgz |
| 最后更新 | 2026-09-17T08:46:31Z |
| Pulse | updated |
| 依赖 | node |
| Bottle | 可用 (于 all) |
| Homebrew post-install | 未定义 |
| 服务 | 未声明 |
注册表事实
| Source Database | Homebrew formula API |
|---|---|
| Tap | homebrew/core |
| Full Name | ni |
| Version Scheme | 0 |
| Revision | 0 |
| Bottle Stable Root URL | https://ghcr.io/v2/homebrew/core |
| Deprecated | no |
| Disabled | no |
| Keg Only | no |
| URL Keys |
|
源数据库匹配
匹配项来自外部软件包管理器索引,并与本地 Automic Vault 软件包链接分开显示。
ni
nix profile install nixpkgs#nind 0.8.2-8.1
small command line interface to WebDAV servers
sudo apt install ndnd 0.8.2-8.1
small command line interface to WebDAV servers
sudo apt install nd来源线索
此页面由 av-web 从 scripts/generate-pkg-sqlite.py 生成的私有软件包 SQLite 工件提供。
View the package source record on GitHub.