Sha256: 45c48dfc7fc2793dd092fc47eb3abebcaba7a6431e0fc8dc6db248bf031a8b4c

Contents?: true

Size: 859 Bytes

Versions: 7

Compression:

Stored size: 859 Bytes

Contents

#!/usr/bin/env ruby

require "bundler/setup"
require "tako"

# You can add fixtures and/or initialization code here to make experimenting
# with your gem easier. You can also use a different console, if you like.

# (If you use this, don't forget to add pry to your Gemfile!)
# require "pry"
# Pry.start

require "pry"

require File.join(File.dirname(__FILE__), "../../", "spec/support/model_class")

ENV["RAILS_ENV"] ||= 'test'
ENV['TAKO_CONFIG_FILE_PATH'] ||= File.join(File.dirname(__FILE__), "../", "spec/config/shards.yml")

database_yml_path = File.join(File.dirname(__FILE__), "../", "spec/config/database.yml")
database_yml = YAML.load(ERB.new(File.read(database_yml_path)).result).with_indifferent_access[:test]
Tako.load_connections_from_yaml
ActiveRecord::Base.establish_connection(database_yml)

opts = Pry::CLI.parse_options
Pry::CLI.start(opts)

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
tako-0.6.0 bin/console
tako-0.5.0 bin/console
tako-0.4.1 bin/console
tako-0.4.0 bin/console
tako-0.3.2 bin/console
tako-0.3.1 bin/console
tako-0.3.0 bin/console