V
V
Vitalij Rudyuk2013-11-24 13:37:33
Webkit
Vitalij Rudyuk, 2013-11-24 13:37:33

Is it possible to create completely portable programs on node-webkit?

Is it possible to create completely portable programs on node-webkit, which would consist of one executable file and store their settings in the folder in which the program itself is located. Ability to work from a flash drive. It is also important that the program works on at least three operating systems: Linux, MacOs, Windows. Where can you read about this? Google didn't help in this case.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alexey Polushin, 2013-11-25
@Faradey

It's difficult without an external binary wrapper. If wrapping everything in a package is still possible, as well as determining the directory from which the binary is launched, then in order to write there, there may already be problems.
With Windows, everything is simple, but for example, in Linux, an application cannot even sneeze without checking access rights. Accordingly, taking and recording anywhere will not work.
You can dig in the following areas:
1. Sandbox . In package.json, you can set the path where node-webkit will save localStorage and temporary files, for example:
2. process.env - allows you to get a bunch of data about the application environment, including finding path data. This also includes process.execPath
Most likely, you will have to, firstly, determine the OS, and secondly, check the access rights to the directory.

O
OnYourLips, 2013-11-24
@OnYourLips

would consist of a single executable file

worked at least on three operating systems: Linux, MacOs, Windows.
It is forbidden.
Why such a strange requirement for 1 executable file?
If you approach the task normally, then you can do it.
The knowledge of an advanced user is enough, no programming is needed.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question