This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var gulp = require('gulp'); | |
| var gutil = require('gulp-util'); | |
| var bower = require('bower'); | |
| var concat = require('gulp-concat'); | |
| var sass = require('gulp-sass'); | |
| var compass = require('gulp-compass'); | |
| var minifyCss = require('gulp-minify-css'); | |
| var rename = require('gulp-rename'); | |
| var sh = require('shelljs'); | |
| var path = require('path'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * @param $baseUrl - non protected part of the URL including hostname, e.g. http://example.com | |
| * @param $path - protected path to the file, e.g. /downloads/myfile.zip | |
| * @param $secret - the shared secret with the nginx server. Keep this info secure!!! | |
| * @param $ttl - the number of seconds until this link expires | |
| * @param $userIp - ip of the user allowed to download | |
| * @return string | |
| */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //- As you may know, Laravel 5 provides the Elixir to compile assets with no pain. | |
| These mixins is for those of you who want to use Jade power combined with that of Laravel Blade. | |
| The syntax mimic Blade statements, however identation differs in some cases. | |
| - var newline = "\r\n" | |
| - var loopIterator = '$iterator' | |
| //- @extends mixin | |
| Example: +extends('layouts/master') | |
| Compiled: @extends('layouts/master') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //- As you may know, Laravel 5 provides the Elixir to compile assets with no pain. | |
| These mixins is for those of you who want to use Jade power combined with that of Laravel Blade. | |
| The syntax mimic Blade statements, however identation differs in some cases. | |
| - var newline = "\r\n" | |
| - var loopIterator = '$iterator' | |
| //- @extends mixin | |
| Example: +extends('layouts/master') | |
| Compiled: @extends('layouts/master') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| DROP FUNCTION IF EXISTS slugify; | |
| DELIMITER ;; | |
| CREATE DEFINER='root'@'localhost' | |
| FUNCTION slugify (temp_string VARCHAR(200) CHARSET utf8) | |
| RETURNS VARCHAR(200) | |
| DETERMINISTIC | |
| BEGIN | |
| DECLARE x, y , z Int; | |
| DECLARE new_string VARCHAR(200); | |
| DECLARE is_allowed Bool; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| create or replace function fn_porcentaje_similitud(cadena1 character varying, cadena2 character varying ) | |
| /* | |
| @author: fbriceno | |
| @descripcion: devuelve el porcentaje de similitud entre 2 cadenas, haciendo uso del algoritmo jaro-winkler | |
| @return: porcentaje de similitud entre 0 y 1. entre mas cercano al 1 mayor coincidencia. mas cercano al 0 poco coincidente | |
| @documentation: https://gist.github.com/fjavier/586c713943d76a023a70 | |
| */ | |
| returns numeric as | |
| $BODY$ | |
| DECLARE |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| apt-get update | |
| #Additional Packages | |
| apt-get install -y cifs-utils winbind smbclient bindfs gvfs gvfs-bin keyutils unzip php5-ldap php5-mssql zsh | |
| wget --no-check-certificate http://install.ohmyz.sh -O - | sh | |
| chsh vagrant -s /bin/zsh |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /* * ** | |
| * | |
| * This script converts an existing MySQL database to migrations in Laravel 4. | |
| * | |
| * 1. Place this file inside app/controllers/ | |
| * | |
| * 2. In this file, edit the index() method to customize this script to your needs. | |
| * - inside $migrate->ignore(), you pass in an array of table |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <? | |
| require("redis.php"); | |
| require("json.php"); | |
| $term = $_GET['term']; | |
| $r = new Redis("127.0.0.1","6379"); | |
| $r->connect(); | |
| $items = $r->zrangebylex("kernel","[$term","[$term\xff",Array("LIMIT","0","10")); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Feel free to change this path of course (and keys_zone value as well, but also change the usage of it below). | |
| proxy_cache_path /var/www/cache/resized levels=1:2 keys_zone=resizedimages:10m max_size=1G; | |
| # Gzip was on in another conf file of mine...You may need to uncomment the next line. | |
| #gzip on; | |
| gzip_disable msie6; | |
| gzip_static on; | |
| gzip_comp_level 4; | |
| gzip_proxied any; | |
| # Again, be careful that you aren't overwriting some other setting from another config's http {} section. |