Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rodnye/onpm
Offline NPM module installer
https://github.com/rodnye/onpm
cache cli modules-storage nodejs npm offline
Last synced: 2 days ago
JSON representation
Offline NPM module installer
- Host: GitHub
- URL: https://github.com/rodnye/onpm
- Owner: rodnye
- License: mit
- Created: 2022-11-04T08:03:45.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-08-31T07:53:46.000Z (5 months ago)
- Last Synced: 2025-01-19T22:09:08.886Z (22 days ago)
- Topics: cache, cli, modules-storage, nodejs, npm, offline
- Language: JavaScript
- Homepage:
- Size: 2.92 MB
- Stars: 7
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# onpm
Offline Npm Manager is a command line tool that allows you to install and manage NPM modules without an internet connection.
## Get Started
To install Offline Npm Manager, run the following command:
```sh
npm i -g onpm-cli
```Once installed, you can use the `onpm` command.
To verify the installation, run:
```sh
onpm --version
```## CLI
### 📥 Download and save in cache
To use Offline Npm Manager, you need to download the required modules first. Use the following command:
```sh
onpm download [ ...] [flags]
```If no modules are specified, it will download the modules specified in the `package.json` file.
For example:
```sh
onpm download express
```After downloading the modules, they will be available for offline installation in other projects.
Flags:
| Flag | Description |
|---------------------------|-------------------------------------------------------|
| `--prod, --production` | Download only package.json dependencies |
| `-f`, `--force` | Download all modules ignoring if already downloaded |
| `--fast` | Download all modules quickly in a single process |### 💽 Install a module
To install the downloaded modules in your NodeJs project, use the following command:
```sh
onpm install [ ...] [flags]
```If no modules are specified, it will install the modules specified in the `package.json` file.
For example, to install the `express` and `moment` modules:
```sh
onpm install express moment --save
```Flags:
| Flag | Description |
|----------------------|-------------------------------------------------------|
| `-S, --save` | Install and add to package.json dependencies |
| `-D, --save-dev` | Install and add to package.json devDependencies |
| `-N, --no-save` | Install without adding to package.json | |### For more information, execute `onpm -h`
## Contributions
Contributions are welcome! If you encounter any issues or have improvements in mind, feel free to open a new issue or submit a pull request.
## License
This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.
##
Created by Rodny Estrada.