-
-
Notifications
You must be signed in to change notification settings - Fork 7.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Explain .nvmrc better #1673
Explain .nvmrc better #1673
Conversation
README.md
Outdated
You can create a `.nvmrc` file containing version number in the project root directory (or any parent directory). | ||
`nvm use`, `nvm install`, `nvm exec`, `nvm run`, and `nvm which` will all respect an `.nvmrc` file when a version is not supplied on the command line. | ||
You can create a `.nvmrc` file containing node version number in the | ||
project root directory (or any parent directory). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please don't hard-wrap sentences; everything anybody uses to view text in the last decade or two has soft-wrapping :-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Except github diffs, terminals and text/plain rendering by browsers, to name the first three things that came to mind.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Terminals all can soft-wrap, as do github diffs (they omit the line number on soft-wrapped lines).
README.md
Outdated
`.nvmrc` being utilized. | ||
|
||
The contents of a `.nvmrc` file **must** be the node version number | ||
or specification followed by a newline. No trailing spaces are allowed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"or specification" isn't very clear; nvm --help
describes it as a "version-ish"; another way to phrase it is "must be the exact argument passed to nvm use
or other nvm
commands, followed by a newline"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
While this is technically correct I don't think it is helping newcomers understand what goes into an nvmrc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think newcomers will understand "specification" when it's not a term that's used anywhere else in docs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feel free to make any changes you want, I will not be offended.
29b2c4d
to
45a2c4c
Compare
Alternative to #1581, though I would say nvm should strip whitespace from the version number in .nvmrc.