Skip to content

Instantly share code, notes, and snippets.

@jsifalda
jsifalda / A) Before start.sh
Created August 12, 2012 11:53
Installation nginx, PHP-FPM and MySQL on OSX Lion
# First, you must install Xcode with plugin Command line tools, which you find in the Preferences -> Downloads
@jsifalda
jsifalda / common.conf
Created August 12, 2012 12:21
Nette nginx configuration
# Please paste to folder common/common.conf
index index.html index.htm;
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
#location ~ \.(js|ico|gif|jpg|png|css|rar|zip|tar\.gz)$ { }
@jsifalda
jsifalda / config
Created August 12, 2012 13:03
GIT: Using SSH over the HTTPS port
#~/.ssh/config
Host github.com
Hostname ssh.github.com
Port 443
#test: ssh -vT git@github.com
@jsifalda
jsifalda / gitignore_global
Created August 12, 2012 13:07
GIT: gitignore global
#add with command: git config --global core.excludesfile ~/.gitignore_global
# Compiled source #
###################
*.com
*.class
*.dll
*.exe
*.o
*.so
<?php
/**
* Object representing a DOM element.
*
* @package PHPUnit_Selenium
* @author Giorgio Sironi <giorgio.sironi@asp-poli.it>
* @copyright 2010-2011 Sebastian Bergmann <sb@sebastian-bergmann.de>
* @license http://www.opensource.org/licenses/BSD-3-Clause The BSD 3-Clause License
* @version Release: @package_version@
@jsifalda
jsifalda / AdminOrders.php
Created August 15, 2012 07:11
Prestashop: How to allow deleting orders
<?php
# version 1.4.8.2
# in file <folder-with-preshashop>/admin/tabs/AdminOrders.php
# find line "$this->colorOnBackground = true;", after that write: $this->delete = true;
#...
class AdminOrders extends AdminTab
{
public function __construct()
@jsifalda
jsifalda / php.ini
Created August 18, 2012 10:32
Xdebug: nginx (php-fpm) and phpStorm configuration
zend_extension="/usr/lib/php/extensions/no-debug-non-zts-20090626/xdebug.so"
[xdebug]
xdebug.idekey="macgdbp"
xdebug.remote_enable=1
xdebug.remote_host="localhost"
xdebug.remote_port=9089
xdebug.remote_handler="dbgp"
@jsifalda
jsifalda / config.neon
Created August 24, 2012 10:23
Nette configurations for PagodaBox cloud hosting (Boxfile)
#config.neon
production < common:
includes:
- production.php
@jsifalda
jsifalda / pagodabox-init.php
Created August 24, 2012 12:33
Simulations of pagodabox environment on local
<?php
$parts = explode(DIRECTORY_SEPARATOR, $_SERVER['PWD']);
$server = $parts[count($parts) - 1];
switch ($server) {
case 'directory':
$_SERVER['DB1_NAME'] = 'database-name';
break;
@jsifalda
jsifalda / gist:3780362
Created September 25, 2012 06:54
Installation PHP 5.4 on OSX with Homebrew (PHP-FPM)
#Optional
#add "export PATH=/usr/local/bin:$PATH #homebrew" into your ~/.profile file
#brew update
#brew doctor
# If you see some warnings, resolve it
#Tap the homebrew/dupes repository into your brew installation:
brew tap homebrew/dupes
#Tap the repository into your brew installation: