Criando um projeto Laravel 5

Pré-requisitos:

1) PHP

2) Composer

Instalação

$ composer create-project laravel/laravel nome_projeto

Configuração

Permissões

Verificar permissões na pasta de projeto criada caso necessário mudar:

chown -R eve contoso.com
chgrp -R www-data contoso.com
chmod -R 750 contoso.com
chmod g+s contoso.com
ls -l
drwxr-s--- 2 eve      www-data   4096 Feb  5 22:52 contoso.com

Virtual Host

Criar virtual host no servidor pois o Laravel utiliza a pasta Public para servidr os arquivos das views:

sudo cp /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/exemplo.com.conf
<VirtualHost *:80>
    ServerAdmin admin@exemplo.com
    ServerName exemplo.com
    ServerAlias www.exemplo.com
    DocumentRoot /var/www/exemplo.com/public_html
    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
sudo a2ensite exemplo.com.conf
sudo service apache2 restart
/etc/hosts
127.0.0.1 localhost 
127.0.0.2 exemplo.com

Tenta acessar por ex: onetouchweb.dev se exibir a página Welcome está correta a instalação se exibir uma página em branco sete as seguintes permissões:

$chmod -R 777 nome_projeto/storage

Agora deve exibir a página de Welcome.

 

Restart Frozen Gnome-Shell

gnome wheater app
gnome wheater app
Gnome Wheater App

I’m trying Gnome 3.10, and it’s awesome! Perhaps when leave my computer for some time it freezes on the protection screen, where we have a clock and arrows indicating that you can swap to get the login screen.

To restart it you need to get into a terminal:

ctrl + alt + F1, login

so you can kill the frozen process using:

pkill -kill gnome-shell

Bye!

Configuring keyboard layout on Fluxbox

This command works but just at the actual session:

# setxkbmap -model abnt2 -layout br -variant abnt2

To keep the layout every time you start your system you need write the keyboard options

at a file if you use Xorg window system try this:

“/etc/X11/xorg.conf.d/00-keyboard.conf”

Section “InputClass”

        Identifier “keyboard”

        MatchIsKeyboard “yes”

        Option “XkbLayout” “br”

        Option “XkbVariant” “abnt2”

        Option “XkbOptions” “”

EndSection

Find Files In Linux

Example:

alexandre@alexandre-dev-pc:~$ sudo find /home/alexandre/Pictures/ -name ‘*.png’

Results on:

/home/alexandre/Pictures/equipe.png
/home/alexandre/Pictures/tutor.png
/home/alexandre/Pictures/start.png
/home/alexandre/Pictures/screenshot.png
/home/alexandre/Pictures/telaPropostas.png
/home/alexandre/Pictures/detach22.png
/home/alexandre/Pictures/editarCampoFormulario.png
/home/alexandre/Pictures/livro1.png
/home/alexandre/Pictures/google_talk_gems_dock_icon_1_8435_3352_image_4233.png
/home/alexandre/Pictures/blog/method1.png
/home/alexandre/Pictures/blog/naming1.png
/home/alexandre/Pictures/blog/naming.png
/home/alexandre/Pictures/detach100.png
/home/alexandre/Pictures/ideiaEzbuy.png
/home/alexandre/Pictures/stageGate_PaginaAprovacao.png
/home/alexandre/Pictures/telaPropostas1.png
/home/alexandre/Pictures/stageGate_PaginaMensagens.png
/home/alexandre/Pictures/chat16.png
/home/alexandre/Pictures/send_16.png
/home/alexandre/Pictures/chat32.png
/home/alexandre/Pictures/resend16.png
/home/alexandre/Pictures/stageGate.png
/home/alexandre/Pictures/requisitos.png
/home/alexandre/Pictures/eventos.png
/home/alexandre/Pictures/tutor22.png

Alexandre Liberato

Search Bash History File

Don’t you remember of a command line that you used some hours ago? I found a simple way to do that:

Just a little, but helpful, tip from the Garrett LeSage’s website.

..to search typed history at a bash prompt, hit control-r and start typing a command you used previously. It doesn’t have to start with what is typed, as it returns matches which contain the searched text.

Hit control-r again (while searching), and it will jump back further in history and search with the same text…

Alexandre Liberato