syam-install
v0.0.2
Published
Smart install CLI that auto-detects your package manager (npm, pnpm, yarn, bun, deno) from lock files.
Maintainers
Readme
syam-install
Smart CLI installer that auto-detects your package manager from lock files and delegates to the right tool.
Installation
npm install -g syam-install
# or
pnpm add -g syam-install
# or
bun add -g syam-installUsage
Install all dependencies
Reads package.json and installs all dependencies + devDependencies using the detected package manager:
syam install
syam iInstall a specific package
syam install express
syam i expressInstall multiple packages
syam install express lodash axios
syam i express lodash axiosInstall globally
syam install -g nodemon
syam i -g nodemon
# Multiple packages globally
syam install -g nodemon typescript tsx
syam i -g nodemon typescript tsxPackage Manager Auto-Detection
syam install looks for lock files in the current directory and maps them to the corresponding package manager:
| Lock File | Package Manager | Underlying Command |
|---|---|---|
| pnpm-lock.yaml | pnpm | pnpm add / pnpm install |
| yarn.lock | yarn | yarn add / yarn install |
| bun.lock / bun.lockb | bun | bun add / bun install |
| deno.lock | deno | deno install |
| package-lock.json | npm | npm install |
| (no lock file found) | npm | npm install |
Detection is based on priority order — pnpm-lock.yaml is checked before package-lock.json.
Examples
$ syam install express
syam detected pnpm via pnpm-lock.yaml
▶ pnpm add express
...pnpm output...
✔ Done!$ syam install -g typescript
syam no lock file found, using npm (default)
▶ npm install -g typescript
...npm output...
✔ Done!Options
| Flag | Description |
|---|---|
| -g, --global | Install package(s) globally |
| -h, --help | Show help |
| -v, --version | Show version |
Related
- syam-init — Interactive project initializer
License
MIT © udenbaguse
