##Given Apache 2 and MySQL are already installed.
#Update MacPorts sudo port selfupdate;sudo port -u upgrade outdated
#Install PHP 5.4.* sudo port install php54 php54-apache2handler ##Activate Apache Module cd /opt/local/apache2/modules
#!/usr/bin/env ruby -w | |
if ARGV.size < 2 | |
puts "Usage: stakeout.rb <command> [files to watch]+" | |
exit 1 | |
end | |
command = ARGV.shift | |
files = {} |
<?php | |
class PHPUnit_Extensions_TestListener_GrowlTestListener | |
implements PHPUnit_Framework_Testlistener | |
{ | |
const TEST_RESULT_COLOR_RED = 'red'; | |
const TEST_RESULT_COLOR_YELLOW = 'yellow'; | |
const TEST_RESULT_COLOR_GREEN = 'green'; | |
private $_errors = array(); |
Index: TicketListener.php | |
=================================================================== | |
--- TicketListener.php | |
+++ TicketListener.php | |
@@ -207,14 +207,16 @@ abstract class PHPUnit_Extensions_TicketListener implements PHPUnit_Framework_Te | |
} else { | |
$adjustTicket = TRUE; | |
} | |
+ | |
+ $ticketInfo = $this->getTicketInfo($ticket); |
<?php | |
/** | |
* PHPUnit | |
* | |
* Copyright (c) 2002-2010, Sebastian Bergmann <[email protected]>. | |
* All rights reserved. | |
* | |
* Redistribution and use in source and binary forms, with or without | |
* modification, are permitted provided that the following conditions | |
* are met: |
<?php | |
define('TEST_KEY', 'are_we_glued'); | |
$redis = new Redis(); | |
try { | |
$redis->connect('localhost', 6379); | |
$redis->set(TEST_KEY, 'yes'); | |
$glueStatus = $redis->get(TEST_KEY); | |
if ($glueStatus) { | |
$testKey = TEST_KEY; | |
echo "Glued with the Redis key value store:" . PHP_EOL; |
#!/usr/bin/php | |
<?php | |
printf("%sGit pre-commit hook %1\$s", PHP_EOL); | |
$projectName = basename(getcwd()); | |
exec('phpunit --configuration phpunit.xml', $output, $returnCode); // Assuming cwd here | |
if ($returnCode !== 0) { | |
$minimalTestSummary = array_pop($output); | |
printf("Test suite for %s failed: ", $projectName); | |
printf("( %s ) %s%2\$s", $minimalTestSummary, PHP_EOL); | |
return false; // exit(1); |
<?php | |
/* | |
* | |
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | |
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | |
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | |
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | |
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | |
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | |
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
#!/usr/bin/php | |
<?php | |
define('DEPENDENT_EXTENSION', 'SimpleXML'); | |
if (!extension_loaded(DEPENDENT_EXTENSION)) { | |
$consoleMessage = sprintf( | |
"Skipping build file checks as the '%s' extension isn't available.", | |
DEPENDENT_EXTENSION | |
); | |
echo $consoleMessage . PHP_EOL; |
$app->after(function (Request $request, Response $response) { | |
$appl = $request->attributes->get('app'); | |
if ($request->get('jsonp_callback') !== null | |
&& $request->getMethod() === 'GET') | |
{ | |
/** | |
* Configured via ConfigServiceProvider (https://github.com/igorw/ConfigServiceProvider) | |
* Example: | |
* |
##Given Apache 2 and MySQL are already installed.
#Update MacPorts sudo port selfupdate;sudo port -u upgrade outdated
#Install PHP 5.4.* sudo port install php54 php54-apache2handler ##Activate Apache Module cd /opt/local/apache2/modules