Skip to content

Add --devdir flag.#916

Merged
bnoordhuis merged 1 commit intonodejs:masterfrom
bnoordhuis:fix21
Oct 7, 2016
Merged

Add --devdir flag.#916
bnoordhuis merged 1 commit intonodejs:masterfrom
bnoordhuis:fix21

Conversation

@bnoordhuis
Copy link
Copy Markdown
Member

Overrides the location where node-gyp will look for (and download to)
the node.js SDK.

For harmonization with the --nodedir flag, osenv.home() is now used
instead of process.env.HOME || process.env.USERPROFILE.

osenv.home() defaults to the built-in os.homedir() when available
and falls back to sane defaults based on the platform.

%USERPROFILE% is now preferred on Windows and %HOME% is ignored;
similarly, UNIX systems ignore $USERPROFILE from now on. Neither
behavior made much sense, IMO.

Fixes: #21

@bnoordhuis
Copy link
Copy Markdown
Member Author

Obsoletes #540.

@rvagg
Copy link
Copy Markdown
Member

rvagg commented Jul 13, 2016

lgtm

@bnoordhuis
Copy link
Copy Markdown
Member Author

Overrides the location where node-gyp will look for (and download to)
the node.js SDK.

For harmonization with the --nodedir flag, `osenv.home()` is now used
instead of `process.env.HOME || process.env.USERPROFILE`.

`osenv.home()` defaults to the built-in `os.homedir()` when available
and falls back to sane defaults based on the platform.

`%USERPROFILE%` is now preferred on Windows and `%HOME%` is ignored;
similarly, UNIX systems ignore `$USERPROFILE` from now on.  Neither
behavior made much sense, IMO.

Fixes: #21
PR-URL: #916
Reviewed-By: Rod Vagg <[email protected]>
@bnoordhuis bnoordhuis merged commit 9c8d275 into nodejs:master Oct 7, 2016
@bnoordhuis bnoordhuis deleted the fix21 branch October 7, 2016 08:36
@as-cii
Copy link
Copy Markdown

as-cii commented Oct 27, 2016

Great work here, @bnoordhuis! Thank you so much! ✨ Is there an ETA for the next node-gyp release that will contain this change? We would like to stop using the $HOME hack in Atom/Electron and the --dev-dir flag would be super helpful!

@bnoordhuis
Copy link
Copy Markdown
Member Author

@as-cii I can probably do a v3.5.0 release next week. There is one open pull request (#919) that I need to look at again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants