Skip to content

tabreezsajjad/nenv

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 

Repository files navigation

🚀 nenv — Per-project Portable Node.js Runtime for Windows

nenv is a lightweight tool that allows any Windows project to use Node.js locally without installing Node globally. It downloads a full Node.js runtime directly into your project:

.nenv/node-vX.Y.Z-win-x64/

All Node/npm commands run using this isolated project runtime.

Perfect for:

  • Corporate / restricted laptops (no admin rights)
  • Zero-install developer setups
  • Multiple projects with different Node versions
  • CI/CD environments without global installs
  • Portable development
  • Reproducible project environments

🌟 Features

  • ✔ Zero global Node installation required
  • ✔ Node stored inside project (.nenv/)
  • ✔ Supports Node versions 14, 16, 18, 20, 22, 24
  • nenv.cmd node uses the project’s local Node
  • nenv.cmd npm install uses local npm
  • nenv.cmd dev, nenv.cmd build, etc.
  • ✔ Downloads official Node.js zips automatically
  • ✔ Fully offline after first download
  • ✔ No dependencies — just PowerShell + CMD
  • ✔ Clean, simple, reproducible

📦 Installation

🚀 Method 1 — Install via jsDelivr CDN (recommended)

Run this inside your project root folder::

Invoke-WebRequest -Uri "https://cdn.jsdelivr.net/gh/tabreezsajjad/nenv@v0.5.0/nenv.txt" -OutFile "nenv.cmd"

Then initialize:

.\nenv.cmd init

This will download Node.js into:

.nenv/node-vX.Y.Z-win-x64/

and generate .nenv-version.


📄 Method 2 — Manual Download

  1. Visit: https://github.com/tabreezsajjad/nenv
  2. Download nenv.txt and save it as nenv.cmd
  3. Place it in your project
  4. Run:
.\nenv.cmd init

🧪 Usage

Check Node version

.\nenv.cmd node --version

Install npm packages

.\nenv.cmd npm install

Run npm scripts

.\nenv.cmd dev
.\nenv.cmd build
.\nenv.cmd start

Equivalent to:

npm run dev
npm run build
npm run start

But always using the project-local Node, never the global system.


📁 Folder Structure

project/
│ nenv.cmd
│ .nenv-version
└── .nenv/
    ├── cache/
    │   └── node-v18.20.0-win-x64.zip
    └── node-v18.20.0-win-x64/
        ├── node.exe
        ├── npm.cmd
        ├── npx.cmd
        └── all Node core files

Everything is sandboxed to this one project.


🎯 Why nenv?

Global Node installations cause:

  • Version conflicts
  • Permission problems
  • Breaking updates
  • Corporate laptop restrictions
  • CI/CD inconsistencies
  • Different versions across teammates

nenv fixes all of this by giving each project its own private Node runtime.


🛠 Roadmap

  • nenv.ps1 PowerShell-native version
  • nenv status
  • nenv switch <version>
  • nenv list
  • Auto-updating mechanism
  • GitHub Pages documentation
  • macOS/Linux support (future)
  • One-line bootstrap installer

❤️ Support

If this project helps you, consider supporting:

Or simply ⭐ star the GitHub repo — it means a lot!


🪪 License

MIT License — free for personal and commercial use.


👨‍💻 Author

Built with ❤️ by Sajjad Tabreez
GitHub: https://github.com/tabreezsajjad/

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors