This file contains 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
{ | |
"layout": { | |
"model": "pc105", | |
"layout": "us", | |
"variant": "", | |
"options": "", | |
"rules": "evdev", | |
"isUSStandard": true, | |
"isUserKeyboardLayout": false | |
}, |
This file contains 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
#include <dlfcn.h> | |
#include <pthread.h> | |
#include <stdio.h> | |
// THIS IS TO AVOID A SIGFAULT WHEN RUNNING python3.6 manage.py runserver | |
// This should be fixed at some point by Alpine and/or Python | |
// Check this issue for more info | |
// https://github.com/docker-library/python/issues/211 | |
typedef int (*func_t)(pthread_t *thread, const pthread_attr_t *attr, void *(*start_routine)(void*), void *arg); |
This file contains 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 -e | |
#### | |
# based on http://www.clock.co.uk/blog/a-guide-on-how-to-cache-npm-install-with-docker | |
# | |
# Set's the last modified timestamp of a file to it's repositories commit timestamp. | |
# | |
# Particularly useful with docker when building after a new git checkout has been made, | |
# can improve docker build times for composer, bower, npm, etc | |
# | |
# @see https://github.com/docker/docker/issues/3556 |
This file contains 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
box: wercker-labs/docker | |
build: | |
steps: | |
- script: | |
name: fix timestamps | |
code: | | |
sudo wget https://gist.githubusercontent.com/davidwindell/fbfef588c6295666c6a1/raw/c2870b13a50a7aeb4aed1e6eb4daec3a905a7fc0/git-timestamp.sh -O /usr/local/bin/git-timestamp | |
sudo chmod +x /usr/local/bin/git-timestamp | |
git-timestamp composer.json | |
git-timestamp composer.lock |
This file contains 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 | |
/** | |
* Handle various type conversions that should be supported natively by Doctrine (like DateTime) | |
* | |
* @param mixed $value | |
* @param string $typeOfField | |
* @return DateTime | |
*/ | |
protected function handleTypeConversions($value, $typeOfField) | |
{ |
This file contains 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 Application\Listener\Doctrine; | |
use Doctrine\DBAL\DBALException; | |
use Doctrine\ORM\EntityManager; | |
use Zend\EventManager\EventInterface; | |
use Zend\Mvc\MvcEvent; | |
class FlushEntities |
This file contains 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
{ | |
"ticket": { | |
"ticketid": 174, | |
"status": "open", | |
"type": "ticket", | |
"subject": "Hello there", | |
"followup": false, | |
"contact": { | |
"contactid": 99, | |
"name": "Person", |
This file contains 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 | |
'doctrine' => array( | |
'configuration' => array( | |
'orm_default' => array( | |
//'sqlLogger' => new \Doctrine\DBAL\Logging\EchoSQLLogger(), | |
), | |
), | |
), |
This file contains 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 My\Form\Element; | |
use Zend\Form\Element\Select as SelectElement; | |
class DepartmentSelect extends SelectElement | |
{ | |
This file contains 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 | |
public function setPosts(array $posts) { | |
foreach ($posts as $post) { | |
if ($this->posts->contains($post)) { | |
return; | |
} | |
$this->posts->add($post); | |
$post->setTicket($this); |
NewerOlder