-
Application\Started
(inCommand::main()
) -
Application\Configured
(inCommand::handleArguments()
) -
Bootstrap\Finished
(inCommand::handleBootstrap()
) -
TestSuite\Loaded
(inBaseTestRunner::getTest()
) -
TestSuite\Configured
(inTestRunner::doRun()
, afterhandleConfiguration()
) -
TestSuite\Sorted
(inTestRunner::doRun()
) -
Extension\Loaded
(inTestRunner::doRun()
)
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
Taken from packagist.org | |
Packages with a master branch update since June 1st 2018: 98977 | |
Of those, package having requires on PHP extensions: 11676 (11.79%) | |
As only ~12% of packages declare their extension requirements, | |
and even then it might not be a complete list, take all this with | |
a big grain of salt, it is informative but definitely not a | |
complete picture of the most used extensions. |
Running a script in the background in linux can be done using nohup
, using nohup we can run node application in the background
$ nohup node server.js > /dev/null 2>&1 &
nohup
means: Do not terminate this process even when the stty is cut off> /dev/null
means: stdout goes to/dev/null
(which is a dummy device that does not record any output)
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 | |
error_reporting(E_ALL); | |
$opts = getopt('f:d:rb:', ['ext:', 'php:', 'diff::']); | |
if ((int)isset($opts['d']) + (int)isset($opts['f']) !== 1) { | |
$self = basename(__FILE__); | |
echo <<<EOF | |
Usage: | |
php $self -f<php_script> [-b] [--php <path_to_php>] [ --diff [<file>]] |
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 AppBundle\Form; | |
use Symfony\Component\Form\AbstractType; | |
use Symfony\Component\Form\Extension\Core\Type\PasswordType; | |
use Symfony\Component\Form\Extension\Core\Type\RepeatedType; | |
use Symfony\Component\Form\Extension\Core\Type\SubmitType; | |
use Symfony\Component\Form\FormBuilderInterface; |
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
// Webpack | |
config.resolve = config.resolve || {}; | |
config.resolve.alias = config.resolve.alias || {}; | |
Object.assign(config.resolve.alias, { | |
jquery: path.join(__dirname, '/client/assets/lib/jquery/jquery.js'), | |
jqueryGritter: path.join(__dirname, '/client/assets/lib/jquery.gritter/js/jquery.gritter.js'), | |
perfectScrollbar: path.join(__dirname, '/client/assets/lib/perfect-scrollbar/js/perfect-scrollbar.jquery.min.js'), |
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
mkdir ~/vim | |
cd ~/vim | |
# Staically linked vim version compiled from https://github.com/ericpruitt/static-vim | |
# Compiled on Jul 20 2017 | |
curl 'https://s3.amazonaws.com/bengoa/vim-static.tar.gz' | tar -xz | |
export VIMRUNTIME="$HOME/vim/runtime" | |
export PATH="$HOME/vim:$PATH" | |
cd - |
- Install PHP-CS-Fixer on your local machine according to these instructions: https://github.com/FriendsOfPHP/PHP-CS-Fixer
- Open PHPStorm, Preferences > Tools > External Tools and enter these values:
- Program, edit to match your path where PHP-CS-Fixer lives:
/.composer/vendor/friendsofphp/php-cs-fixer/php-cs-fixer
- Parameters:
--rules=@PSR2 --verbose fix $FileDir$/$FileName$
. Note that previous verions of PHP-CS-Fixer used--levels
instead of--rules
. - Working directory:
$ProjectFileDir$
Click OK and Apply. Now we'll set up a shortcut.
- Go to Preferences > Keymap and search for "PHP Fixer" (or whatever name you gave it). Add whatever shortcut you like, I'm using
ctrl + cmd + ]
:
Source: http://www.syahzul.com/2016/04/06/how-to-install-oci8-on-ubuntu-14-04-and-php-5-6/
Download the Oracle Instant Client and SDK from Oracle website. (Need to login in Oracle page)
http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html
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
use Symfony\Component\Security\Core\Authentication\Token\UsernamePasswordToken; | |
// Manually authenticate user in controller | |
$token = new UsernamePasswordToken($user, null, 'main', $user->getRoles()); | |
$this->get('security.token_storage')->setToken($token); | |
$this->get('session')->set('_security_main', serialize($token)); |
NewerOlder