Skip to content

Instantly share code, notes, and snippets.

View pedrommone's full-sized avatar
🎯
Focusing

Pedro Maia pedrommone

🎯
Focusing
View GitHub Profile
{
"atomic_save": false,
"bold_folder_labels": true,
"caret_style": "phase",
"color_scheme": "Packages/User/SublimeLinter/Monokai - Spacegray Eighties (SL).tmTheme",
"detect_indentation": false,
"fade_fold_buttons": false,
"font_face": "inputMonoNarrow",
"font_size": 14,
"highlight_line": true,
server {
client_max_body_size 20M;
listen 80 default_server;
root /data/www/public;
index index.php index.html index.htm;
location / {
try_files $uri $uri/ /index.html /index.php?$query_string;
}
server {
resolver 169.254.169.250 8.8.8.8 8.8.4.4 valid=300s;
client_max_body_size 20M;
listen 80 default_server;
root /data/www/public;
index index.php index.html index.htm;
location / {
<?xml version="1.0" encoding="UTF-8"?>
<project name="landing-page-qa" default="gulp" basedir=".">
<target name="npm_install" description="Install NPM dependencies">
<exec executable="npm">
<arg value="install"/>
</exec>
</target>
<target name="bower_install" description="Install Bower dependencies">
{
"atomic_save": false,
"caret_extra_width": 2,
"color_scheme": "Packages/Color Scheme - Default/Monokai.tmTheme",
"detect_indentation": false,
"font_face": "inputMonoNarrow",
"font_size": 11,
"highlight_line": true,
"ignored_packages":
[
@pedrommone
pedrommone / home.blade.php
Created December 23, 2014 11:42
Socket.io implementantion with Redis, Laravel and Node.
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Laravel PHP Framework</title>
<style>
</style>
<script src="https://cdn.socket.io/socket.io-1.2.1.js"></script>
@pedrommone
pedrommone / gist:c259ba7b0864ee77ab3a
Created September 17, 2014 15:44
Search music youtube link
<?php
$search_url = "https://www.youtube.com/results?search_query=";
$musics = file_get_contents('rdio.json');
$header[] = "Accept: application/json, text/plain, */*";
$header[] = "Referer: https://youtube.com/";
$header[] = "Connection: keep-alive";
$header[] = "Accept-Charset: utf-8;q=0.7,*;q=0.7";
$header[] = "Accept-Language: en-US,en;q=0.8,pt-BR;q=0.6,pt;q=0.4";
@pedrommone
pedrommone / gist:670eef51ad35ef5a307a
Created September 17, 2014 12:01
Grab favorited music from rdio
(function() {
var musics = [];
var paper = $('.collection_item .lower_content').each(function() {
musics.push({
"title": $(this).find('.grid_item_title').html(),
"author": $(this).find('.grid_item_subtitle').html()
});
});
/*
* Translated default messages for the jQuery validation plugin.
* Locale: PT_BR
*/
jQuery.extend(jQuery.validator.messages, {
required: "Campo obrigatório!",
remote: "Por favor, corrija este campo.",
email: "Por favor, forneça um endereço eletrônico válido.",
url: "Por favor, forneça uma URL válida.",
date: "Por favor, forneça uma data válida.",
var SITE = SITE || {};
SITE.fileInputs = function() {
var $this = $(this),
$val = $this.val(),
valArray = $val.split('\\'),
newVal = valArray[valArray.length-1],
$button = $this.siblings('.button'),
$fakeFile = $this.siblings('.file-holder');
if(newVal !== '') {