class Writefully::Tools::Synchronizer

Constants

SYNC_SCRIPT

Attributes

message[R]

Public Class Methods

new(message) click to toggle source
# File lib/writefully/tools/synchronizer.rb, line 10
def initialize message
  @message = message
end

Public Instance Methods

sync() click to toggle source
# File lib/writefully/tools/synchronizer.rb, line 14
def sync
  Writefully.logger.info "Synchronizing #{message[:site_slug]}"
  system(sync_command)
end
sync_command() click to toggle source
# File lib/writefully/tools/synchronizer.rb, line 19
def sync_command
  ['bash', SYNC_SCRIPT, Writefully.options[:content], message[:site_slug]].join(' ')
end