Skip to content

Instantly share code, notes, and snippets.


Vladimir Vukanac vukanac

View GitHub Profile
vukanac /
Created Aug 20, 2017
How to install php72 on Mac OS X with homebrew.

Skip this:

brew tap homebrew/dupes
brew tap homebrew/versions


Warning: homebrew/dupes was deprecated. This tap is now empty as all its formulae were migrated.
Warning: homebrew/versions was deprecated. This tap is now empty as all its formulae were migrated.
aknackd /
Last active Mar 5, 2020
Laravel Dusk for Selenium using Docker

Configuring Laravel Dusk for Selenium using Docker

Start Docker containers

First, we need to run a Selenium Hub and a Firefox Selenium node:

$ docker run -d --name hub -p 4444:4444 selenium/hub
$ docker run -d --name fx --link hub:hub selenium/node-firefox
w00fz /
Last active Jun 2, 2020
PHP switcher
# Check if command was ran as root.
if [[ $(id -u) -eq 0 ]]; then
echo "The command \"sphp\" should not be executed as root or via sudo directly."
echo "When a service requires root access, you will be prompted for a password as needed."
exit 1
# Usage
tristanlins / iconv.docker
Created Oct 10, 2015
Docker PHP extension recipes
View iconv.docker
FROM php:5.6-cli
RUN apt-get update \
&& apt-get install -y \
libfreetype6-dev \
&& rm -rf /var/lib/apt/lists/* \
&& docker-php-ext-install iconv \
&& apt-get remove -y \
libfreetype6-dev \
&& apt-get install -y \
mikefrancis /
Last active Jan 26, 2020
PSR-2 Build System using Sublime Text

PSR-2 Build System using Sublime Text


Open a new terminal and install Composer:

curl -sS | php
mv composer.phar /usr/local/bin/composer

Once that has finished installing and moved, install the PHP-CS-Fixer Composer package globally:

View gist:9188393
$countries = array
'AF' => 'Afghanistan',
'AX' => 'Aland Islands',
'AL' => 'Albania',
'DZ' => 'Algeria',
'AS' => 'American Samoa',
'AD' => 'Andorra',
pete-otaqui /
Created Dec 2, 2012
Bump a software project's VERSION, add the CHANGES, and tag with GIT
# works with a file called VERSION in the current directory,
# the contents of which should be a semantic version number
# such as "1.2.3"
# this script will display the current version, automatically
# suggest a "minor" version update, and ask for input to use
# the suggestion, or a newly entered value.
tPl0ch / build.xml
Created Dec 2, 2012
Ant build file for PHP projects including Behat build task
View build.xml
<?xml version="1.0" encoding="utf-8"?>
<project name="your-project-name-here" default="build">
<target name="build"
<target name="build-parallel"
<target name="tools-parallel" description="Run tools in parallel">
<parallel threadCount="2">
ziadoz / Version20121011141021.php
Created Oct 11, 2012
Doctrine DBAL and Migrations Example
View Version20121011141021.php
* /path/to/migrations/directory/Version20121011141021.php
namespace ExampleMigrations;
use Doctrine\DBAL\Migrations\AbstractMigration;
use Doctrine\DBAL\Schema\Schema;
class Version20121011141021 extends AbstractMigration
You can’t perform that action at this time.