Different development environments (Mac & Windows)

You need to have 2 sets of settings one for if file_exists and one for else:

if ( file_exists( dirname( __FILE__ ) . '/local-config.php' ) ) {
  include( dirname( __FILE__ ) . '/local-config.php' );
  define( 'WP_LOCAL_DEV', true ); 
} else {
  define('WP_HOME', 'http://localhost:666/projectname/');
  define('WP_SITEURL', 'http://localhost/foldername/wordpress/');
}