Search code examples
ruby-on-railspostgresqlzshitermoh-my-zsh

zsh: permission denied: bin/rake


I have recently bought a new Macbook and have installed Rails, Ruby, Git, Homebrew, and Postgres successfully. I can open my app in atom but when I try to run a migration or drop the database, ZSH gives me a permission denied error. Is there something I'm missing / have forgotten to install?

➜ SYT git:(master) ✗ bin/rake db:migrate zsh: permission denied: bin/rake ➜ SYT git:(master) ✗ bin/rake db:drop zsh: permission denied: bin/rake


Solution

  • Apparently the contents of bin directory do not have permission to be executed. You can fix it with

    chmod +x bin/*