Node.js on Windows. When and why?

Note. A similar question is called "installing nodejs on a Windows machine." And various answers explaining how by installing cygwin you can get it to work there.

Now I do not want to install cygwin. I just wish I could start nodejs in a window window.

I want to run "nodejs.exe".

Can someone explain to me

1) why nodejs was not ported to windows - what are the technical reasons for not providing exe?

2) are there any plans to have nodejs on windows?

I really would like to use it, but I cannot accept that I have to accept cygwin. This is simply not so.

+6
source share
2 answers

Update:

For the optimal node for Windows development, I recommend using Windows PowerShell for node.js. This is a powerful optimization for using node, npm and the azure APIs. (azure apis are optional. I would still use this powershell if I hadn't used azure).

When : v0.6

Currently you can get a binary that (view) works under windows. Go ask in the node.js IRC channel They will let you down.

Basically, if you read plans on the roads of node.js, you will find that proper window support is planned at 0.6, we are currently at v0.4.7, and the beta version of v0.5.x is in a complete storm.

I will not give ETA, but soon.

IRC can be found in Community Links

PDF showing v0.6 roadmap

July 2011 Update:

#nodejs v0.5.1 is the first to ship with the official Windows executable. We hope to get a good feedback.

Microsoft is officially involved in the joy of creating node.js for Windows.

+11
source

Running Node on Windows presents several technical issues, mainly related to how the internal design of Windows differs from how Linux and the “change of mind” are required to port Unix applications to Windows.

Background

Linux was designed to replace Unix, a well-known multi-tasking operating system, so from the first day it was a multi-user / multi-processor, server-oriented operating system. The idea of ​​sharing multiple system resources is the key to its internal design.

Windows was originally designed as a single-user / single-processor desktop operating system and therefore did not support sharing system resources. In 1993, Microsoft released a new redesigned version of Windows - called Windows / NT - to better support the shared resource, the multi-tasking model required by the servers, but because of the existing user base set, Microsoft required that NT also support all the features of its single-user / single-task predecessor .

Windows 7 is a direct descendant of NT and Microsoft needs the support of outdated users to this day (and, according to many, it is very confused about the internal design of Windows).

Microsoft also hired a system architect named Dave Cutler to develop NT. Dave is best known for developing a Unix competitor called VMS, whose internal design is significantly different from Linux design, which has caused many problems for developers interested in porting their Unix programs to Windows.

The clearest example of this “impedance mismatch” between the internal design of Windows and Linux is how they handle the event-driven non-blocking input / output (io), on which Node relies on its (seemingly) multitasking magic in a single operation flow.

Linux supports two system functions, called select () and epoll (), which can be used to asynchronously inform the process of changes in the operating system that affect it. Node is heavily dependent on these features, but Windows also does not support it, relying instead on “Change notifications” (mostly) to handle event-driven io.

+6
source

Source: https://habr.com/ru/post/888552/


All Articles