Sha256: bcb00eed4b570b1c02192287eeaa36459256e58e75efac6db19c59f2d0fc2225

Contents?: true

Size: 730 Bytes

Versions: 15

Compression:

Stored size: 730 Bytes

Contents

# frozen_string_literal: true

require_relative 'entangler/version'
require_relative 'entangler/errors'
require_relative 'entangler/logger'
require_relative 'entangler/entangled_file'

module Entangler
  class << self
    attr_accessor :executor

    def run(base_dir, opts = {})
      opts = { mode: 'master', remote_mode: true }.merge(opts)

      require 'entangler/executor/base'
      if opts[:mode] == 'master'
        require 'entangler/executor/master'
        self.executor = Entangler::Executor::Master.new(base_dir, opts)
      elsif opts[:mode] == 'slave'
        require 'entangler/executor/slave'
        self.executor = Entangler::Executor::Slave.new(base_dir, opts)
      end

      executor.run
    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
entangler-1.6.1 lib/entangler.rb
entangler-1.6.0 lib/entangler.rb
entangler-1.5.1 lib/entangler.rb
entangler-1.5.0 lib/entangler.rb
entangler-1.4.1 lib/entangler.rb
entangler-1.4.0 lib/entangler.rb
entangler-1.3.3 lib/entangler.rb
entangler-1.3.2 lib/entangler.rb
entangler-1.3.1 lib/entangler.rb
entangler-1.3.0 lib/entangler.rb
entangler-1.2.3 lib/entangler.rb
entangler-1.2.2 lib/entangler.rb
entangler-1.2.1 lib/entangler.rb
entangler-1.2.0 lib/entangler.rb
entangler-1.1.2 lib/entangler.rb