Sha256: aaf7405d3509e7aa0ac25840813c188428b178587fe2a09ef77eca70847ad8cb
Contents?: true
Size: 1.01 KB
Versions: 1
Compression:
Stored size: 1.01 KB
Contents
# install @rails/request.js if Rails.root.join("config/importmap.rb").exist? say "Pin @rails/request.js" append_to_file "config/importmap.rb", %(pin "@rails/request.js", preload: true\n) else say "Install @rails/request.js" run "yarn add @rails/request.js" end gemfile = Rails.root.join("Gemfile").read # install stimulus-rails, if not already present if !gemfile.include? "stimulus-rails" gem "stimulus-rails" rails_command "stimulus:install" say "✅ stimulus-rails has been installed" else say "⏩ stimulus-rails is already installed. Skipping." end # copy stimulus controller template generate "solder:stimulus" # turn on development caching if Rails.root.join("tmp", "caching-dev.txt").exist? say "⏩ Already caching in development. Skipping." else system "rails dev:cache" say "✅ Enabled caching in development" end # mount engine route 'mount Solder::Engine, at: "/solder"' # copy initializer template generate "solder:initializer" if yes?("Do you want to install the solder initializer template?")
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
solder-0.3.0 | lib/install/install.rb |