Skip to content

Commit

Permalink
Update order of install generator
Browse files Browse the repository at this point in the history
  • Loading branch information
jcoyne committed Jan 30, 2024
1 parent 3c182f1 commit c988068
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 13 deletions.
18 changes: 7 additions & 11 deletions lib/generators/spotlight/install_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -152,24 +152,20 @@ def add_mailer_defaults
end
end

def generate_config
directory 'config'
end

def add_solr_config_resources
copy_file '.solr_wrapper.yml', '.solr_wrapper.yml'
directory 'solr'
end

def generate_devise_invitable
gem 'devise_invitable'
bundle_install
generate 'devise_invitable:install'
generate 'devise_invitable', 'User'
end

def add_translations
copy_file 'config/initializers/translation.rb'
def generate_config
directory 'config'
end

def add_solr_config_resources
copy_file '.solr_wrapper.yml', '.solr_wrapper.yml'
directory 'solr'
end

def configure_logging
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@
# Don't allow initializer to break if DB doesn't exist yet
# see: https://github.com/projectblacklight/spotlight/issues/2133
if ENV['SKIP_TRANSLATION'].blank?
raise unless Translation.table_exists?

unless Translation.table_exists?
warn "Translation table doesn't exist. Skipping translation config."
next
end
##
# Sets up the new Spotlight Translation backend, backed by ActiveRecord. To
# turn on the ActiveRecord backend, uncomment the following lines.
Expand Down

0 comments on commit c988068

Please sign in to comment.