This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| class Tx_MyExt_Controller_BaseController extends Tx_Extbase_MVC_Controller_ActionController { | |
| /** | |
| * @see Tx_Extbase_MVC_Controller_ActionController::callActionMethod() | |
| */ | |
| protected function callActionMethod() { | |
| $this->validateAll(); | |
| parent::callActionMethod(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # script: watch | |
| # author: Mike Smullin <[email protected]> | |
| # license: GPLv3 | |
| # description: | |
| # watches the given path for changes | |
| # and executes a given command when changes occur | |
| # usage: | |
| # watch <path> <cmd...> | |
| # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ; Spawn fcgiwrap as the user owning the git repositories, with a socket writeable by nginx | |
| [fcgi-program:fcgiwrap_gitolite] | |
| command = /usr/sbin/fcgiwrap | |
| user = gitolite | |
| socket = unix:///var/run/supervisor/%(program_name)s.sock | |
| socket_owner = gitolite:nginx | |
| socket_mode = 0770 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # Use socat to proxy git through an HTTP CONNECT firewall. | |
| # Useful if you are trying to clone git:// from inside a company. | |
| # Requires that the proxy allows CONNECT to port 9418. | |
| # | |
| # Save this file as gitproxy somewhere in your path (e.g., ~/bin) and then run | |
| # chmod +x gitproxy | |
| # git config --global core.gitproxy gitproxy | |
| # | |
| # More details at http://tinyurl.com/8xvpny |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // Context: I'm trying to argue that DI (and DIC) are great, and DIC libs suck. | |
| // Happy to be proven wrong! | |
| final class Router { | |
| private $dependencies; | |
| public function __construct (Dependencies $dependencies) { | |
| $this->dependencies = $dependencies; | |
| // You might say that this is Service Locator, but it's not. This router is toplevel, | |
| // and toplevel must have access to dependencies. After that it can all just bubble nicely using proper DI. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.boohoo.esbdefused.metrics; | |
| import java.util.Arrays; | |
| import java.util.concurrent.TimeUnit; | |
| import com.codahale.metrics.Counter; | |
| import com.codahale.metrics.Gauge; | |
| import com.codahale.metrics.Histogram; | |
| import com.codahale.metrics.Meter; | |
| import com.codahale.metrics.MetricRegistry; |