GREP_OPTIONS environment variable can cause last_sync/last_upgrade failure

Fixes #11

Sorry for double request, first was done in error, closed it