DEV Community

Discussion on: How to Setup Tailwind 3 on Rails 7

Collapse
 
alexandrerojon profile image
Alexandre

Hey Akshay!
Thanks for the setup, super useful and it works perfectly. :) Quick question on step 5 specifically - is there a way to automate this or avoid having to run this command every time?
Thanks in advance :)

Collapse
 
software_writer profile image
Akshay Khot • Edited

Hey Alexandre,

Thanks for the kind words, I really appreciate it.

Since I posted this article, Tailwind has updated their documentation to include steps for Ruby on Rails. Please check it out.

To answer your original question, yes, you can definitely automate this setup. Take a look at the Foreman project.

When using Foreman, you create a single Procfile, that lists all background processes that need to be started for your application to work. This lets you start your Rails server, database server, Tailwind, Redis, etc. using a single command. Here is a sample Procfile.

Hope that helps.

Akshay

Collapse
 
alexandrerojon profile image
Alexandre

Thanks Akshay! Appreciate you taking the time to respond to me :)