Skip to content

Commit

Permalink
Load environment before running tasks (SpinaCMS#955)
Browse files Browse the repository at this point in the history
  • Loading branch information
Bramjetten authored Jan 29, 2022
1 parent 46ab950 commit b321f3d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/tasks/tailwind.rake
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ SPINA_TAILWIND_COMPILE_COMMAND = "#{Tailwindcss::Engine.root.join("exe/tailwindc
namespace :spina do
namespace :tailwind do
desc "Build your Tailwind CSS"
task :build do
task build: :environment do
Rails::Generators.invoke("spina:tailwind_config", ["--force"])
system SPINA_TAILWIND_COMPILE_COMMAND
end

task :watch do
task watch: :environment do
Rails::Generators.invoke("spina:tailwind_config", ["--force"])
system "#{SPINA_TAILWIND_COMPILE_COMMAND} -w"
end
Expand Down

0 comments on commit b321f3d

Please sign in to comment.