Sha256: a250a98a6c7eb113f3726ecda4e794e45998518bf49e1647324cf54e986b051d

Contents?: true

Size: 546 Bytes

Versions: 11

Compression:

Stored size: 546 Bytes

Contents

module Cloner::Internal
  extend ActiveSupport::Concern
  include Cloner::MongoDB
  include Cloner::Ar
  include Cloner::Postgres
  include Cloner::MySQL
  include Cloner::SSH
  include Cloner::RSync

  def e(str)
    Shellwords.escape(str)
  end

  def load_env
    unless defined?(Rails)
      require rails_path
    end
    require 'net/ssh'
  end

  def verbose?
    false
  end
  def env_from
    ENV['CLONE_FROM'] || 'production'
  end

  def clone_db
    if defined?(Mongoid)
      clone_mongodb
    else
      clone_ar
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
cloner-0.13.0 lib/cloner/internal.rb
cloner-0.12.0 lib/cloner/internal.rb
cloner-0.11.0 lib/cloner/internal.rb
cloner-0.10.0 lib/cloner/internal.rb
cloner-0.9.2 lib/cloner/internal.rb
cloner-0.9.1 lib/cloner/internal.rb
cloner-0.9.0 lib/cloner/internal.rb
cloner-0.8.0 lib/cloner/internal.rb
cloner-0.7.0 lib/cloner/internal.rb
cloner-0.6.1 lib/cloner/internal.rb
cloner-0.6.0 lib/cloner/internal.rb