vagrant box add centos-6.3 https://s3.amazonaws.com/itmat-public/centos-6.3-chef-10.14.2.box
mkdir vagrant-lamp
vagrant init centos-6.3
<?php | |
/** | |
* Restringe o acesso às páginas fora da white list. útil para controlar login. | |
* | |
* @param Zend\Mvc\MvcEvent $e Instância | |
* @param Mixed $authService Instância do serviço de autenticação | |
* @param Array $whiteListRoutes Lista de rotas na white list (Sem precisar de login) | |
* @param String $loginRoute Nome da rota para o login | |
* @link http://stackoverflow.com/questions/14137868/zend-framework-2-global-check-for-authentication-with-zfcuser |
RewriteEngine On | |
# The following rule tells Apache that if the requested filename | |
# exists, simply serve it. | |
RewriteCond %{REQUEST_FILENAME} -s [OR] | |
RewriteCond %{REQUEST_FILENAME} -l [OR] | |
RewriteCond %{REQUEST_FILENAME} -d | |
RewriteRule ^.*$ - [NC,L] | |
# The following rewrites all other queries to index.php. The | |
# condition ensures that if you are using Apache aliases to do | |
# mass virtual hosting, the base path will be prepended to |
<VirtualHost *:80> | |
ServerName application.local | |
DocumentRoot <application-path>/public | |
SetEnv APPLICATION_ENV development | |
<Directory <application-path>/public> | |
AllowOverride All | |
Require all granted | |
</Directory> | |
</VirtualHost> |
<?php | |
namespace Application\Controller; | |
use Zend\Mvc\Controller\AbstractActionController; | |
use Zend\View\Model\ViewModel; | |
class IndexController extends AbstractActionController | |
{ | |
public function indexAction() | |
{ |
----------------------------------------- | |
Novos branches | |
----------------------------------------- | |
1 - Criar branch | |
1.1 - Atualizar repositório do trunk | |
svn up | |
1.2 - Fazer cópia do trunk para a pasta dos branches | |
svn cp http://svn.fcl.com.br/svn/<nome-do-projeto>/trunk http://svn.fcl.com.br/svn/<nome-do-projeto>/branches/<nome-do-branch> -m "Comentário..." |
/* A resposta para a vida o universo e tudo mais = 42. Douglas Adams (Guia do mochileiro das galáxias) | |
* | |
* Google: https://www.google.com/webhp?sourceid=chrome-instant&ie=UTF-8&ion=1#hl=pt-BR&safe=off&sclient=psy- ab&q=resposta%20para%20a%20vida%20o%20universo%20e%20tudo%20mais&oq=&gs_l=&pbx=1&fp=e8f2ebbc99d26e1a&ion=1&bav=on.2,or.r_gc.r_pw.r_cp.r_qf.&biw=1920&bih=915 | |
* | |
* What the fuck Javascript: http://wtfjs.com/2011/11/11/the-universe-answers-and-JavaScript-still-makes-us-wtf | |
*/ | |
var resposta = "3" -+-+-+ "1" + "1" / "3" * "6" + "2"; | |
alert(resposta); |
# Path to your oh-my-zsh configuration. | |
ZSH=$HOME/.oh-my-zsh | |
# Set name of the theme to load. | |
# Look in ~/.oh-my-zsh/themes/ | |
# Optionally, if you set this to "random", it'll load a random theme each | |
# time that oh-my-zsh is loaded. | |
# export ZSH_THEME="random" | |
export ZSH_THEME="prose" |
# Theme based on: | |
# http://stevelosh.com/blog/2010/02/my-extravagant-zsh-prompt/ | |
# http://fendrich.se/blog/2012/09/28/no/ | |
function prompt_char { | |
git branch >/dev/null 2>/dev/null && echo '±' && return | |
hg root >/dev/null 2>/dev/null && echo '☿' && return | |
echo '%(!.!.➜)' | |
} |
# apache - mysql - mongo - redis - php5 - ruby + python + postgresql + gearman + memcache | |
# Refs: | |
# https://help.ubuntu.com/community/ApacheMySQLPHP | |
# https://docs.google.com/document/d/1m4xb0lmgxzmi4OnLPZp5A7Thab-xL-_SfZi1bq7c18Q/edit | |
# :: Apache :: | |
# :: PHP :: |