0
0
mirror of https://github.com/tj/n.git synced 2024-11-21 18:48:57 +01:00

Add How It Works ro README and prepare for release

This commit is contained in:
John Gee 2019-11-23 17:54:41 +13:00
parent f42094a930
commit cc524e98a3
3 changed files with 17 additions and 2 deletions

View File

@ -7,7 +7,11 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
<!-- markdownlint-disable MD024 -->
## [Unreleased] (date goes here)
## [6.1.3] (2019-11-23)
### Added
- added How It Works to README
### Changed
@ -235,6 +239,7 @@ Only minor functional changes, but technically could break scripts relying on sp
<!-- reference links for releases -->
[Unreleased]: https://github.com/tj/n/compare/master...develop
[6.1.3]: https://github.com/tj/n/compare/v6.0.2...v6.1.3
[6.1.2]: https://github.com/tj/n/compare/v6.0.1...v6.1.2
[6.1.1]: https://github.com/tj/n/compare/v6.0.0...v6.1.1
[6.1.0]: https://github.com/tj/n/compare/v6.0.1...v6.1.0

View File

@ -22,6 +22,7 @@ Node.js version management: no subshells, no profile setup, no convoluted API, j
- [Custom Source](#custom-source)
- [Custom Architecture](#custom-architecture)
- [Optional Environment Variables](#optional-environment-variables)
- [How It Works](#how-it-works)
## Installation
@ -203,3 +204,12 @@ In brief:
- `N_NODE_DOWNLOAD_MIRROR`: See [Custom source](#custom-source)
- support for [NO_COLOR](http://no-color.org) and [CLICOLOR=0](https://bixense.com/clicolors) for controlling use of ANSI color codes
- `N_MAX_REMOTE_MATCHES` to change the default `ls-remote` maximum of 20 matching versions
## How It Works
`n` downloads a prebuilt `node` package and installs to a single prefix (e.g. `/usr/local`). This overwrites the previous version. The `bin` folder in this location should be in your `PATH` (e.g. `/usr/local/bin`).
The downloads are kept in a cache folder to be used for reinstalls. The downloads are also available for limited use using `n which` and `n run` and `n exec`.
The global `npm` packages are not changed by the install, with the
exception of `npm` itself which is part of the `node` install.

2
bin/n
View File

@ -40,7 +40,7 @@ function echo_red() {
# Setup and state
#
VERSION="6.1.3-0"
VERSION="6.1.3"
N_PREFIX="${N_PREFIX-/usr/local}"
N_PREFIX=${N_PREFIX%/}