Can't setup tailwind css with rails

Although I followed all the steps and even tried the --css-tailwind pre-configured project setup I always get the same Error

/var/lib/gems/3.0.0/gems/tailwindcss-rails-2.0.27-x86_64-linux/exe/x86_64-linux/tailwindcss: 1: ELF: not found
/var/lib/gems/3.0.0/gems/tailwindcss-rails-2.0.27-x86_64-linux/exe/x86_64-linux/tailwindcss: 4: Syntax error: word unexpected (expecting ")")
rails aborted!
Command failed with exit 2: /var/lib/gems/3.0.0/gems/tailwindcss-rails-2.0.27-x86_64-linux/exe/x86_64-linux/tailwindcss

Tasks: TOP => assets:precompile => tailwindcss:build
(See full trace by running task with --trace)

Additionally, I get the following when I try to use the tailwind

The asset "tailwind.css" is not present in the asset pipeline.

NOTE: I am using ubuntu 22.04.2 via WSL version 1

…I followed all the steps…

did you mean the steps mentioned by the gem?

Official tailwind documentation Install Tailwind CSS with Ruby on Rails - Tailwind CSS

Have you tried doing a bundle install/update just to check the gem installed successfully?

Default rails new app plus bundle add tailwindcss-rails and rails tailwindcss:install

ruby “3.2.0” # I think the tutorial is set for 3.2.1 gem “rails”, “~> 7.0.4”, “>=” gem “sprockets-rails” gem “puma”, “~> 5.0” gem “importmap-rails” gem “turbo-rails” gem “stimulus-rails” gem “tailwindcss-rails”, “~> 2.0”

Works fine on macOS. I just did this session a day or two ago.

Beyond what was asked but Tailwindcss removes some formatting but a class ‘prose’ at top level adds basic formatting.

yes I did, I made sure its installed

It looks like there is something wrong with your tailwind executable

can you run tailwindcss from the command line?

if not try “gem uninstall tailwindcss-rails” and then run bundler again.