Skip to content

Instantly share code, notes, and snippets.

View anyt's full-sized avatar

Andrii Yatsenko anyt

View GitHub Profile
[xdebug]
;zend_extension="/usr/local/opt/php71-xdebug/xdebug.so"
xdebug.max_nesting_level = 1000
xdebug.idekey="PHPSTORM"
xdebug.remote_enable=On
xdebug.remote_connect_back=ON
xdebug.remote_port=9001
xdebug.remote_autostart=1
#xdebug.remote_log=/Users/anyt/Sites/logs/xdebug.log
@anyt
anyt / doctrine
Last active November 3, 2016 16:57
cloc statistic
-------------------------------------------------------------------------------
Language files blank comment code
-------------------------------------------------------------------------------
PHP 981 19853 60748 73262
XML 58 217 18 1418
Markdown 20 500 0 1400
YAML 56 138 3 1012
XSD 3 116 17 973
JSON 13 0 0 516
Twig 2 67 2 391
@anyt
anyt / fooButton.html.twig
Created September 19, 2016 18:15
Add button to "More Actions" dropdown
{{ UI.clientButton({
'dataUrl': path(
'acme_demo_foo_route', {
entityClass: oro_class_name(entity, true),
entityId: entity.id
}),
'aCss': 'no-hash',
'iCss': 'icon-comment-alt',
'dataId': entity.id,
'label': 'acme_demo.contact.action.foo'|trans,
layout:
actions:
- @add:
id: meta_title
parentId: head
blockType: meta
options:
name: 'title'
content: '=data["navigation_title"].getTitle()'
<?php
use Symfony\Component\ClassLoader\ApcClassLoader;
use Symfony\Component\HttpFoundation\Request;
$loader = require_once __DIR__.'/../app/bootstrap.php.cache';
// Use APC for autoloading to improve performance
// Change 'sf2' by the prefix you want in order to prevent key conflict with another application
/*
@anyt
anyt / .bash_profile
Last active June 16, 2016 08:03
My dev env
#############
# Colors #
#############
export PS1=" \[\e[32;1m\]\u\[\e[0m\]\[\e[32m\]@\h\[\e[36m\]\w \[\e[33m\]\$ \[\e[0m\]"
#export PATH=/usr/local/bin:$PATH
#export PATH=/Applications/MAMP/bin/php/php5.6.2/bin/:$PATH
#export ORO_PHP_PATH=/Applications/MAMP/bin/php/php5.6.2/bin/
#export PATH=/usr/local/php5/bin:$PATH
#export PATH="$(brew --prefix homebrew/php/php56)/bin:$PATH"
services:
orob2b_checkout.layout.block.type.abstract_transition_button:
abstract: true
parent: oro_layout.block_type.abstract_configurable
calls:
- [setOptions, [{transitionData: {required: true}, checkout: {required: true}}]]
checkout_information:
blockType: container
options:
vars:
workflowStep: { '@value': $data.workflowStep }
stepOrder: '-'
@anyt
anyt / layout.yml
Last active February 22, 2016 18:52
test_block:
blockType: loop
options:
data: [[1,2], [3,4], [5,6]]
elementName: firstLevelElement
blockType: loop
options:
data: $firstLevelElement
elementName: secondLevelElement
blockType: options
<?php
class A {
protected $kernel;
public function handle() {
print 1;
}