Open directory in file explorer

In ms Windows from node.js , how can I open a specific directory (for example:) c:\documentsin Windows Explorer?

I think in C # this will be:

`process.Start(@"c:\test")`.
+4
source share
1 answer

Try the following:

require('child_process').exec('start "" "c:\\test"');

Note. If your path does not contain spaces, you can also leave with 'start c:\test', but above - which requires ""both a second argument and doubling the instances \in the path (3rd) argument - the most reliable approach.

+6
source

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


All Articles