lib/vagrant-vaimo-unison/plugin.rb in vagrant-vaimo-unison-1.1.2 vs lib/vagrant-vaimo-unison/plugin.rb in vagrant-vaimo-unison-2.0.0

- old
+ new

@@ -4,16 +4,17 @@ raise 'The vagrant-unison plugin must be run within Vagrant.' end # This is a sanity check to make sure no one is attempting to install # this into an early Vagrant version. -if Vagrant::VERSION < '1.9.0' - raise 'The vagrant-unison plugin is only compatible with Vagrant 1.9+' +if Vagrant::VERSION < '2.0.0' + raise 'The vagrant-unison plugin is only compatible with Vagrant 2.0+' end module VagrantPlugins module Unison + # Unison Plugin class Plugin < Vagrant.plugin('2') name 'Unison' description <<-DESC This plugin syncs files over SSH from a local folder to your Vagrant VM (local or on AWS). @@ -23,53 +24,34 @@ require_relative 'config' Config end command 'unison-sync' do + # Setup logging and i18n setup_logging setup_i18n - #Return the command + # Return the command require_relative 'command' CommandSync end - command 'unison-sync-once' do - setup_logging - setup_i18n - - #Return the command - require_relative 'command' - CommandOnce - end - command 'unison-sync-interact' do # Setup logging and i18n setup_logging setup_i18n - #Return the command + # Return the command require_relative 'command' CommandInteract end - - command 'unison-sync-polling' do - # Setup logging and i18n - setup_logging - setup_i18n - - #Return the command - require_relative 'command' - CommandPolling - end - command 'unison-cleanup' do # Setup logging and i18n setup_logging setup_i18n - #Return the command + # Return the command require_relative 'command' CommandCleanup end # This initializes the internationalization strings.