mirror of
https://github.com/neocities/neocities.git
synced 2025-08-01 23:31:52 +02:00
try to get travis build working
This commit is contained in:
parent
d83cef0e09
commit
d6f567e765
3 changed files with 21 additions and 1 deletions
|
@ -12,7 +12,16 @@ require 'zip'
|
|||
Bundler.require
|
||||
Bundler.require :development if ENV['RACK_ENV'] == 'development'
|
||||
|
||||
$config = YAML.load_file(File.join(DIR_ROOT, 'config.yml'))[ENV['RACK_ENV']]
|
||||
if ENV['TRAVIS']
|
||||
$config = YAML.load_file File.join(DIR_ROOT, 'config.yml.travis')
|
||||
else
|
||||
begin
|
||||
$config = YAML.load_file(File.join(DIR_ROOT, 'config.yml'))[ENV['RACK_ENV']]
|
||||
rescue Errno::ENOENT
|
||||
puts "ERROR: Please provide a config.yml file."
|
||||
exit
|
||||
end
|
||||
end
|
||||
|
||||
DB = Sequel.connect $config['database'], sslmode: 'disable', max_connections: $config['database_pool']
|
||||
DB.extension :pagination
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue