$ brew install autoconf automake gmp homebrew/versions/bison27 gd freetype t1lib gettext zlib mcrypt
$ git clone --depth=1 https://github.com/php/php-src.git
$ cd php-src
| The MIT License (MIT) | |
| Copyright (c) James Dennes | |
| Permission is hereby granted, free of charge, to any person obtaining a copy | |
| of this software and associated documentation files (the "Software"), to deal | |
| in the Software without restriction, including without limitation the rights | |
| to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
| copies of the Software, and to permit persons to whom the Software is | |
| furnished to do so, subject to the following conditions: |
| # | |
| # Slightly tighter CORS config for nginx | |
| # | |
| # A modification of https://gist.github.com/1064640/ to include a white-list of URLs | |
| # | |
| # Despite the W3C guidance suggesting that a list of origins can be passed as part of | |
| # Access-Control-Allow-Origin headers, several browsers (well, at least Firefox) | |
| # don't seem to play nicely with this. | |
| # |
| header( 'Content-type: image/gif' ); | |
| # The transparent, beacon image | |
| echo chr(71).chr(73).chr(70).chr(56).chr(57).chr(97). | |
| chr(1).chr(0).chr(1).chr(0).chr(128).chr(0). | |
| chr(0).chr(0).chr(0).chr(0).chr(0).chr(0).chr(0). | |
| chr(33).chr(249).chr(4).chr(1).chr(0).chr(0). | |
| chr(0).chr(0).chr(44).chr(0).chr(0).chr(0).chr(0). | |
| chr(1).chr(0).chr(1).chr(0).chr(0).chr(2).chr(2). | |
| chr(68).chr(1).chr(0).chr(59); |
| // Support routines for automatically reporting user timing for common analytics platforms | |
| // Currently supports Google Analytics, Boomerang and SOASTA mPulse | |
| // In the case of boomerang, you will need to map the event names you want reported | |
| // to timer names (for mPulse these need to be custom0, custom1, etc) using a global variable: | |
| // rumMapping = {'aft': 'custom0'}; | |
| (function() { | |
| var wtt = function(n, t, b) { | |
| t = Math.round(t); | |
| if (t >= 0 && t < 3600000) { | |
| // Google Analytics |
| # Install `dnsmasq` and configure for *.test domains | |
| $ brew install dnsmasq | |
| $ vim /usr/local/etc/dnsmasq.conf | |
| # Reload configuration and clear cache | |
| $ sudo launchctl unload /Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist | |
| $ sudo launchctl load /Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist | |
| $ dscacheutil -flushcache |
Reference: RFC 2616 - HTTP Status Code Definitions
Dockerfile that is based on your production image and
simply install xdebug into it. Exemple:FROM php:5
RUN yes | pecl install xdebug \
&& echo "zend_extension=$(find /usr/local/lib/php/extensions/ -name xdebug.so)" > /usr/local/etc/php/conf.d/xdebug.ini \
| namespace App\Http\Middleware; | |
| use Illuminate\Support\Facades\Log; | |
| class LogAfterRequest { | |
| public function handle($request, \Closure $next) | |
| { | |
| return $next($request); | |
| } |
| #!/bin/sh | |
| set -e | |
| vendor/bin/phpunit | |
| (git push) || true | |
| git checkout production | |
| git merge master |