Sha256: 214ab20b23510c471ad976d343436f1e029f0e081ae4a821cfaaecdbdfab5153
Contents?: true
Size: 862 Bytes
Versions: 5
Compression:
Stored size: 862 Bytes
Contents
def run_turbo_install_template(path) system "#{RbConfig.ruby} ./bin/rails app:template LOCATION=#{File.expand_path("../install/#{path}.rb", __dir__)}" end namespace :turbo do desc "Install Turbo into the app" task :install do if defined?(Webpacker::Engine) Rake::Task["turbo:install:webpacker"].invoke else Rake::Task["turbo:install:asset_pipeline"].invoke end end namespace :install do desc "Install Turbo into the app with asset pipeline" task :asset_pipeline do run_turbo_install_template "turbo_with_asset_pipeline" end desc "Install Turbo into the app with webpacker" task :webpacker do run_turbo_install_template "turbo_with_webpacker" end desc "Switch on Redis and use it in development" task :redis do run_turbo_install_template "turbo_needs_redis" end end end
Version data entries
5 entries across 5 versions & 1 rubygems