Skip to content

Instantly share code, notes, and snippets.

View Freeaqingme's full-sized avatar
💭
Hello? Is this thing on?

Dolf Schimmel Freeaqingme

💭
Hello? Is this thing on?
View GitHub Profile
@Freeaqingme
Freeaqingme / gist:5026299
Created February 24, 2013 23:50
ZendServer MongoDB Packaging...
vagrant@houdini:~/tmp$ apt-get download php-5.4-mongo-zend-server
Get:1 Downloading php-5.4-mongo-zend-server 5.4.11+b1 [106 kB]
Fetched 106 kB in 0s (227 kB/s)
vagrant@houdini:~/tmp$ ar vx php-5.4-mongo-zend-server_5.4.11+b1_amd64.deb
x - debian-binary
x - control.tar.gz
x - data.tar.gz
vagrant@houdini:~/tmp$ tar xvf data.tar.gz
./
./usr/
@Freeaqingme
Freeaqingme / gist:5011931
Created February 22, 2013 09:08
PHP: Log parse errors to syslog()
<?php
register_shutdown_function(function() {
$error = error_get_last();
if (!$error) {
return;
}
switch($error['type']){
case E_ERROR:
require({
// The base path for all packages and modules. If you don't provide this, baseUrl defaults to the directory
// that contains dojo.js. Since all packages are in the root, we just leave it blank. (If you change this, you
// will also need to update `app.profile.js`).
baseUrl: '/',
// A list of packages to register. Strictly speaking, you do not need to register any packages,
// but you can't require "app" and get app/main.js if you do not register the "app" package (the loader will look
// for a module at <baseUrl>/app.js instead). Unregistered packages also cannot use the `map` feature, which
// might be important to you if you need to relocate dependencies. TL;DR, register all your packages all the time:
@Freeaqingme
Freeaqingme / .bashrc
Last active December 12, 2015 09:09
My .bashrc
#!/bin/bash
# YELLOW="\[\033[0;33m\]"
black='\e[0;30m'
blue='\e[0;34m'
green='\e[0;32m'
cyan='\e[0;36m'
red='\e[0;31m'
purple='\e[0;35m'
brown='\e[0;33m'
dolf@dolf-ThinkPad-T530:~/Projects/WegenerApi$ php5 test.php
PHP Warning: Xdebug MUST be loaded as a Zend extension in Unknown on line 0
PHP Notice: Undefined variable: php_errormsg in /home/dolf/Projects/WegenerApi/test.php on line 5
PHP Stack trace:
PHP 1. {main}() /home/dolf/Projects/WegenerApi/test.php:0
NULL
string(32) "Undefined variable: php_errormsg"
<?php
class ServiceManager extends ZendServiceManager
{
public function getSubClasses($class, $directOnly = true)
{
$class .= '\\';
$length = strlen($class);
$filtered = array();
$cNames = $this->getCanonicalNames();
#layout{
background-image: linear-gradient(bottom, #7D7D7D 42%, #FAFAFA 100%);
background-image: -o-linear-gradient(bottom, #7D7D7D 42%, #FAFAFA 100%);
background-image: -moz-linear-gradient(bottom, #7D7D7D 42%, #FAFAFA 100%);
background-image: -webkit-linear-gradient(bottom, #7D7D7D 42%, #FAFAFA 100%);
background-image: -ms-linear-gradient(bottom, #7D7D7D 42%, #FAFAFA 100%);
background-image: -webkit-gradient(
linear,
left bottom,
@Freeaqingme
Freeaqingme / zf2-workflow.txt
Created September 14, 2012 20:11 — forked from weierophinney/zf2-workflow.txt
proposed workflow
We rename "master" to "develop"
We rename "release" to "master"
Thus "master" stays the default branch, which means most PRs will be made
against it.
Bugfixes are merged to:
- master
- develop
Features are merged to:
- develop
When develop looks like the next minor or major version:
<?php
/**
* Zend Framework (http://framework.zend.com/)
*
* @link http://github.com/zendframework/ZendSkeletonApplication for the canonical source repository
* @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
namespace Application;
@Freeaqingme
Freeaqingme / strategy handling.php
Created July 18, 2012 22:01
THIS IS PSEUDOCODE
<?php
// tHIS ENTIRE FILE IS PSEUDOCODE ONLY
class ConsoleStrategy implements ListenerAggregateInterface
{
/**
* @var \Zend\Stdlib\CallbackHandler[]
*/
protected $listeners = array();