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/bash | |
| set -e | |
| set -u | |
| set -o pipefail | |
| COMMAND=${1:-"help"} | |
| MACHINE_NAME=myapp | |
| DENV=${DENV:-"dev"} |
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 | |
| namespace EntityMapperFramework { | |
| class EntityMapper { | |
| public function __construct() { | |
| stream_wrapper_register('dynamicproxygenerator', __NAMESPACE__ . '\DynamicProxyGeneratorStream'); | |
| } | |
| public function createProxy($entity) { | |
| $class = get_class($entity); |
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
| f(events) -> state | |
| match f(state, event) -> state | |
| f(state, command) -> events |
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
| fromAll() | |
| fromStream(‘streamName’) | |
| fromStreams([‘stream1’, ‘stream2’]) | |
| fromStreamOfStreams(‘streamName’) | |
| fromCategory(‘categoryName’) | |
| foreachStream() | |
| (selectino) | |
| matching: | |
| whenAny( // function(s, e) ) |
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/bash | |
| # Disclaimer - make backups, use at your own risk. | |
| # | |
| # Based on this comment: http://stackoverflow.com/a/13944924/843067 | |
| # Views and stored procedures have to be done separately. | |
| OLDDB="old_db_name" | |
| NEWDB="new_db_name" | |
| MYSQL="mysql -u root -pyour_password " |
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
| FROM ubuntu:14.04 | |
| # Install PHP5-FPM | |
| RUN \ | |
| apt-get update && \ | |
| apt-get install -y \ | |
| vim \ | |
| curl \ | |
| wget \ | |
| build-essential && \ | |
| apt-get install -y \ |
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 | |
| namespace Laravel\Doctrine; | |
| use Doctrine\Common\Proxy\Proxy; | |
| use Doctrine\Common\Collections\Collection; | |
| use Doctrine\Common\Persistence\ObjectManager; | |
| class Serializer { |
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 Category extends Phalcon\Mvc\Model | |
| { | |
| public $id; | |
| public $lft; | |
| public $rgt; |
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 | |
| /** | |
| * TimThumb by Ben Gillbanks and Mark Maunder | |
| * Based on work done by Tim McDaniels and Darren Hoyt | |
| * http://code.google.com/p/timthumb/ | |
| * | |
| * GNU General Public License, version 2 | |
| * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html | |
| * | |
| * Examples and documentation available on the project homepage |
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/bash | |
| # fail fast | |
| set -e | |
| PHP5_FCGI_PATH=/usr/lib/cgi-bin/php5-fpm | |
| PHP5_FCGI_SOCKET=/var/run/php5-fpm.sock | |
| # Make sure the multiverse is enabled | |
| IS_MULTIVERSE_ENABLED=`cat /etc/apt/sources.list | grep -v "^#" | grep multiverse | wc -l` |
NewerOlder