tombenner/wp-mvc — Issue #5: OSX MAMP php CLI
Author: ivansf
Created: 2012-02-03 23:44:11+00:00
State: open

I ran into this issued and maybe it could be documented somewhere. On OSX if you are using MAMP for development, the command "php" using the shell won't connect to the database because you are running the binary included on the OS.

To fix that, open "wpmvc" included in the plugin and provide the proper route to php

#!/bin/bash
mvc_core_path="$(dirname $0)/core/"
/Applications/MAMP/bin/php5.3/bin/php -q "${mvc_core_path}wpmvc.php" "$@"