code: function() {
    if (!watching) return;
  
    hooks.on('action', function(event, name) {
      if (event == 'stopped' || event == 'failed')
        remove('start', name);
    });
  
    hooks.on('trigger', function(event, name) {
      if (event == 'stopped')
        remove('watch', name);
    });
  }
docs: listen for new commands and add them to storage, in case the app crashes