class Wordmove::Doctor::Rsync

Attributes

logger[R]

Public Class Methods

new() click to toggle source
# File lib/wordmove/doctor/rsync.rb, line 6
def initialize
  @logger = Logger.new(STDOUT).tap { |l| l.level = Logger::INFO }
end

Public Instance Methods

check!() click to toggle source
# File lib/wordmove/doctor/rsync.rb, line 10
def check!
  logger.task "Checking rsync"

  if (version = /\d\.\d.\d/.match(`rsync --version | head -n1`)[0])
    logger.success "rsync is installed at version #{version}"
  else
    logger.error "rsync not found. And belive me: it's really strange it's not there."
  end
end