Remove support for `service whisper on/off` because Whisper cannot be started without first disabling it in the communications config, then restarting Embark.
Add documentation for the `service [process] on/off` command
This command was only added a few commits back so it is not considered a breaking change.
Refactor the `service [process] on/off` commands so that there is only one command. Previously we had a command registered for each process, ie:
```
service blockchain on/off
service ipfs on/off
…
```
Now, we only have one command with many options:
```
service [process] on/off - Starts/stops the process. Options: blockchain, embark, ipfs, api
```
Whisper is deliberately not included in the available options for the aforementioned reasons.
This enables removing unnecessary `core/fs` dependencies which can be
replaced with `fs-extra`.
This commit also fixes a bug introduced in f868d1216d
where methods from `embark.fs` weren't available.
The reason for that is because we have several *Process instances
that are created through child process communication, specifically
process.send() APIs. Using those APIs, we can only send data structures
however, methods attached on any of those will get lost.
This is the case when sending embark.fs through process.send().
We still need fs in those places though, mostly because they are relying
on embarkPath and dappPath().
These places are now importing those functions from `embark-core`. Other
API such as writeFile or mkdirp() can be accessed through fs-extra
or fs modules.
This avoids mistakenly placing process event handlers on the parent process
whenever the `embark-core` package is loaded. Also, don't listen for an
`'exit'` event on `process` and then call `process.exit(0)` since the event "is
emitted after the child process ends" ([docs][docs]), i.e. it's unnecessary to
do so and in any case it's not correct to always exit with code `0`.
[docs]: https://nodejs.org/docs/latest-v10.x/api/child_process.html#child_process_event_exit