in short, creating a new rails app with tailwind css option in my linux terminal (e.g.):
~$ rails new depot --css tailwind --database=postqresql
does not create the necessary files to run the following command:
~/depot$ bin/dev
which when trying to run it at the mean time returns the error below:
bash: bin/dev: No such file or directory
i tried looking for this issue in coding communities, but to no avail
(please bear with me , i'm a newbie at this domain)
I was working on this same problem this past week. Running Rails 7.2.1 Here are the steps I went through. Since you mentioned you are a newbie at this domain I'm making no assumptions.
Your local environment needs to have Postgres installed and the user setup beforehand.
Tailwind wasn't installed to my app even though I declared it as a an option/variable when creating the app. So I installed it again. - Install Tailwind on Rails
Set the Postgres gem to 1.5.7 in Gemfile as it was failing during installation
gem "pg", "1.5.7"
Run bundle install
to install gems
Create .env in root directory and add database credentials to .env
POSTGRES_DEV_PASSWORD=yourpasswordhere
Add database env variables to config/database.yml.
development:
<<: *default
database: postgres_development_database
username: your_postgres_username
password: <%= ENV["POSTGRES_DEV_PASSWORD"] %>
host: '127.0.0.1'
Run database migrations. bin/rails db:migrate