Add support for run only once
Add support for run only once

Sometimes you would like to control externally (using a crontab) for example, how often you want to scan an index a hard drive.
Also, you might want to do it only once so you don't need to "watch" for changes.

In such a case, waiting for a message in logs is far from being ideal.

Let's add a new option `loop` which defines the number of runs we want before exiting:

* `X` where X is a negative value means infinite, like `-1` (default)
* `0` means that we don't run FSCrawler. Well... Not sure what could be the usage. May be checking that the configuration file is correct?
* `X` where X is a positive value is the number of runs before it stops.

If you want to scan your hard drive only once, run with `--loop 1`.

Based on https://github.com/dadoonet/fscrawler/issues/223#issuecomment-245300835

Closes #227.

kneubi/fscrawler,dadoonet/fscrawler,dadoonet/fsriver,kneubi/fscrawler,dadoonet/fsriver,dadoonet/fsriver,kneubi/fscrawler,dadoonet/fscrawler,dadoonet/fscrawler