Skip to content

Instantly share code, notes, and snippets.

View lucasprogamer's full-sized avatar
🕶️
Working on Code

Lucas lucasprogamer

🕶️
Working on Code
View GitHub Profile
@lucasprogamer
lucasprogamer / set-robot-git-ftp.md
Created June 22, 2018 18:58
git ftp no setrobot

.git-ftp-ignore | Conteúdo abaixo

bower_components/* node_modules/*

.git-ftp-include | Conteúdo abaixo

vendor/:composer.lock

Dentro da pasta .git, checar arquivo config

<?php
function devplus_attachments_wpquery_where( $where ){
if( is_user_logged_in() ){
// we spreken over een ingelogde user
if( isset( $_POST['action'] ) ){
// library query
if( $_POST['action'] == 'query-attachments' ){
$where .= ' AND post_parent != 0';
}
@lucasprogamer
lucasprogamer / Vagrantfile
Created July 30, 2017 21:52
Setting vagrant-hostmanager
if Vagrant.has_plugin? 'vagrant-hostmanager'
config.hostmanager.enabled = true
config.hostmanager.manage_host = true
config.hostmanager.manage_guest = true
config.vm.provision :hostmanager
settings = YAML::load(File.read(homesteadYamlPath))
config.hostmanager.aliases = settings['sites'].map { |item| item['map'] }
puts "hostmanager aliases: " + config.hostmanager.aliases.join(' ')
@lucasprogamer
lucasprogamer / ui.datepicker-pt-BR.js
Created July 25, 2017 18:39 — forked from Senhordim/ui.datepicker-pt-BR.js
Tradução datepicker pt-BR
/* Brazilian initialisation for the jQuery UI date picker plugin. */
/* Written by Leonildo Costa Silva (leocsilva@gmail.com). */
jQuery(function($){
$.datepicker.regional['pt-BR'] = {
closeText: 'Fechar',
prevText: '&#x3c;Anterior',
nextText: 'Pr&oacute;ximo&#x3e;',
currentText: 'Hoje',
monthNames: ['Janeiro','Fevereiro','Mar&ccedil;o','Abril','Maio','Junho',
'Julho','Agosto','Setembro','Outubro','Novembro','Dezembro'],
Menu->Tools->Developer->New Snipper..
<!-- dd($object) -->
<snippet>
<tabTrigger>dd</tabTrigger>
<content><![CDATA[
dd(${1:this});
]]></content>
</snippet>
@lucasprogamer
lucasprogamer / estados-cidades.json
Created August 31, 2016 20:29 — forked from letanure/estados-cidades.json
JSON estados cidades
{
"estados": [
{
"sigla": "AC",
"nome": "Acre",
"cidades": [
"Acrelândia",
"Assis Brasil",
"Brasiléia",
"Bujari",
#!/bin/bash
homestead up
homestead ssh
apt-get update
#Additional Packages
apt-get install -y zsh