Sha256: ce040cadc8c9361af70f3f719089acd8d386f399b352e363705fd0397a48b3a2
Contents?: true
Size: 1.19 KB
Versions: 50
Compression:
Stored size: 1.19 KB
Contents
# frozen_string_literal: true require "ariadne/view_components/commands" namespace :ariadne_view_components do desc "Build Ariadne View Components CSS" task :build do |_, args| debug = args.extras.include?("debug") command = Ariadne::ViewComponents::Commands.compile_command(debug: debug) puts command.inspect system(*command, exception: true) end desc "Watch and build Ariadne View Components CSS on file changes" task :watch do |_, args| debug = args.extras.include?("debug") poll = args.extras.include?("poll") command = Ariadne::ViewComponents::Commands.watch_command(debug: debug, poll: poll) puts command.inspect system(*command) end desc "Prepares the project for release" task :prepare do |_, _args| FileUtils.rm_rf("app/assets/javascripts") system("script/prepare") end end Rake::Task["assets:precompile"].enhance(["ariadne_view_components:build"]) if Rake::Task.task_defined?("assets:precompile") if Rake::Task.task_defined?("test:prepare") Rake::Task["test:prepare"].enhance(["ariadne_view_components:build"]) elsif Rake::Task.task_defined?("db:test:prepare") Rake::Task["db:test:prepare"].enhance(["ariadne_view_components:build"]) end
Version data entries
50 entries across 50 versions & 1 rubygems