Skip to content
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

install,windows: symlink iojs -> node? #140

Closed
bnoordhuis opened this issue Dec 10, 2014 · 16 comments
Closed

install,windows: symlink iojs -> node? #140

bnoordhuis opened this issue Dec 10, 2014 · 16 comments
Assignees
Labels
question Issues that look for answers.
Milestone

Comments

@bnoordhuis
Copy link
Member

Per today's TC meeting, we're going to rename the binary to iojs and ln -s iojs node on install, provided there isn't already a binary with that name in the target directory.

Symlinks on Windows require elevated privileges and are therefore probably not an option. What to do? I see two options:

  1. Only install iojs, no symlink. Least amount of effort.
  2. Provide a stub node.exe or node.cmd (if that works) that executes iojs.
  3. Something else - but what?

Input welcome.

/cc @domenic @piscisaureus

@domenic
Copy link
Contributor

domenic commented Dec 10, 2014

For reasons @piscisaureus probably understands better than me (I think PATH_EXT is involved?), the stub node.exe (not node.cmd) will give the most seamless experience. That is what Git does as of ~1.8 on Windows, if I recall.

@gkatsev
Copy link

gkatsev commented Dec 10, 2014

Windows, starting with Vista, supports actual symlinks. But one of the other solutions is probably best if windows XP support is needed.

@domenic
Copy link
Contributor

domenic commented Dec 10, 2014

@gkatsev without elevated privileges?

@gkatsev
Copy link

gkatsev commented Dec 10, 2014

@domenic elevated privileges are needed for writing to privileged areas like C:/Program Files et al, but otherwise, doesn't require extra privileges.

@piscisaureus
Copy link
Contributor

@gkatsev If wish you were right but you are not. On windows creating symlinks always requires elevation.

@gkatsev
Copy link

gkatsev commented Dec 11, 2014

Interesting, I was certain it didn't require elevation. I just tried it just to be sure and it does. That really is too bad.

@kkoopa
Copy link

kkoopa commented Dec 11, 2014

I posted in that other thread, but if this is more on topic, I'll repost it:

NAN requires executing 'node' to find the location of the header. Windows compatibility is the main source of problems when it comes to using multiple alternative names. nodejs/nan#70

@rstacruz
Copy link

-1 on this. io.js looks like it will have some breaking API changes from node.js, which means cross-compatibility of io.js and node.js apps won't always be 100% guaranteed. having a node symlink by default may hold progress back.

@kessler
Copy link

kessler commented Dec 21, 2014

@bnoordhuis @domenic @piscisaureus it is quite common for installers to require elevation on windows, why not just do that?

@bnoordhuis
Copy link
Member Author

Short update: after some discussion, it got clear that it's not really possible to reliably detect if an existing install was done by joyent/node, iojs or a mashup of the two (e.g. an iojs install that got scribbled over by joyent/node.) The tentative conclusion is that we are not going to try and simply trust that the user knows what s/he is doing.

@piscisaureus piscisaureus added this to the v1.0.0 milestone Dec 30, 2014
@geek
Copy link
Member

geek commented Jan 9, 2015

Instead of iojs why not just io. In this day and age do we really need the js... Facebook vs The Facebook

@YurySolovyov
Copy link

@geek it was mentioned earlier that io already conflicts with some programming languages

@geek
Copy link
Member

geek commented Jan 9, 2015

For the package name iojs makes sense, but for the bin it should just be io.

Let those who want to install the io language binary and the iojs binary sort out the conflict.... all 5 of them.

@rvagg
Copy link
Member

rvagg commented Jan 12, 2015

Windows installers and binaries are being uploaded in the nightlies now but npm doesn't work obviously because there is no node so they are hard to test

@rvagg rvagg mentioned this issue Jan 12, 2015
14 tasks
@richorama
Copy link

Some native modules do seem to require a node.exe file, so supplying that as a binary would be the only way of maintaining 100% compatiblity.

For the record, adding the files node.cmd and node.exe.cmd containing the single line:

@iojs.exe %*

...seems to work nicely for me in the more general case (i.e. npm works).

@Fishrock123
Copy link
Contributor

@bnoordhuis can this be closed?

@rvagg rvagg closed this as completed Jan 19, 2015
boingoing pushed a commit to boingoing/node that referenced this issue Apr 6, 2017
Mechanical source transformation
Ran the napi files through clang-format
Fixed up the remaining errors by hand
Also fixed a couple warnings

Generated with following commandline:
clang-format -style="{BasedOnStyle: Google,
                      BinPackArguments: false,
                      BinPackParameters: false,
                      PointerAlignment: Left,
                      AllowAllParametersOfDeclarationOnNextLine: false}"

Reviewed by: @mhdawson
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Issues that look for answers.
Projects
None yet
Development

No branches or pull requests