Skip to content

Instantly share code, notes, and snippets.

View leohmoraes's full-sized avatar
🏠
Working/Learning and Hackathon from home

Léo Moraes leohmoraes

🏠
Working/Learning and Hackathon from home
View GitHub Profile
@leohmoraes
leohmoraes / homestead hosts laravel br.md
Last active August 29, 2015 14:26
Adicionar um host no /etc/hosts no Mac #homestead #laravel

Script para adicionar um host local rapidamente no terminal

adicione o codigo abaixo dentro do teu ~/.bash_profile

  function novohost() {
  	if [[ "$1" ]]
  		then
  		 	sudo bash -c 'echo -e "192.168.10.10\t'$1'\n" >> /etc/hosts'
  			echo $1" direcionado para 192.168.10.10 (vagrant homestead)"
Chrome, Firefox
Dash
Skype
OmniDiskSweeper
SmartGit
PhotoShop
GitBook
Eudb
github
ClientMyMac
@leohmoraes
leohmoraes / mac-software.md
Last active August 29, 2015 14:26 — forked from garethrees/mac-software.md
Mac Software

Mac Software

Essential software to install. Most are used often, while some are utilities that come in handy now and then.

#Setting up apache on Mac

Standards

For consitency reasons all repositories to be placed as follows:

  /home/sites   <--- where projects live
  /home/vhosts  <--- vhosts files for those projects
  /home/logs    <--- logs files for those projects
@leohmoraes
leohmoraes / principais_packages.md
Last active August 29, 2015 14:27 — forked from vluzrmos/principais_packages.md
Lista dos principais packages para Laravel citados no 16º Hangout Laravel Brasil.
@leohmoraes
leohmoraes / docker.md
Last active August 29, 2015 14:27 — forked from vallettea/docker.md
Docker

Install on mac:

Install brew and brew cask

brew update
brew tap phinze/homebrew-cask
brew install brew-cask
@leohmoraes
leohmoraes / README.md
Created October 7, 2015 18:09
Custom Package Control repositories
@leohmoraes
leohmoraes / autocomplete.php
Created October 23, 2015 19:09 — forked from imranismail/autocomplete.php
Laravel And JqueryUI's Autocomplete Plugin
//SearchController.php
public function autocomplete(){
$term = Input::get('term');
$results = array();
$queries = DB::table('users')
->where('first_name', 'LIKE', '%'.$term.'%')
->orWhere('last_name', 'LIKE', '%'.$term.'%')
->take(5)->get();
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
# ...
config.vm.provision 'shell', inline: <<-SCRIPT
curl -s -L -O https://github.com/brodock/apt-select/releases/download/0.1.0/apt-select_0.1.0-0_all.deb && sudo dpkg -i apt-select_0.1.0-0_all.deb
apt-select && sudo apt-select-update
SCRIPT
#...
end