I have just post a question but I post an other one because the problem is not the one I had in thought when asking the latter.
So, I am running some rails app on osx, when I run rails s, everything works fine. If I shut down the apache server (mamp) and if I run rails s again, I have this message
Can't connect to local MySQL server through socket '/Applications/MAMP/tmp/mysql/mysql.sock',
which for sure is normal. For info, my mamp server is running, and the connection must pass through /Applications/MAMP/Library/bin/mysql, so I aliased it by setting in my bash profile :
alias mysql="/Applications/MAMP/Library/bin/mysql"
Now, when I launch a rails generate command type, I get this message :
/$root/vendor/bundle/ruby/2.0.0/gems/mysql2-0.3.11/lib/mysql2/client.rb:44:in `connect': Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) (Mysql2::Error)
So how it can be ?