This file contains 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
#!/usr/bin/python | |
import subprocess | |
archivos = subprocess.check_output(["git", "diff", "HEAD^", "HEAD", "--name-only"]) | |
try: | |
print subprocess.check_output("grep -nHe console " + archivos.replace('\n', ' '), stderr=subprocess.STDOUT, shell=True) | |
except Exception, e: | |
This file contains 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
"C:\Program Files\Sublime Text 2\sublime_text.exe" --wait --new-window "%1" |
This file contains 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 | |
function new_nav_menu_items($output) { | |
$idstr = preg_match_all('/<li class="page_item page-item-(\d+)/', $output, $matches); | |
foreach($matches[1] as $mid){ | |
$slug = basename(get_permalink($mid)); | |
$output = preg_replace('/page-item-'.$mid.'(| current_page_item)">/', 'page-item-'.$mid.' page-item-'.$slug.'">', $output, 1); | |
} |
This file contains 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
[ | |
{ | |
"es": "lunes", | |
"en": "monday" | |
}, | |
{ | |
"es": "martes", | |
"en": "tuesday" | |
} | |
, |
This file contains 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 | |
$url = 'url'; | |
$proxyauth = 'user:pass'; | |
$proxy = 'proxy.server.es'; | |
$proxyPort = '8080'; | |
$ch = curl_init(); | |
curl_setopt($ch, CURLOPT_URL, $url); | |
//proxy suport |
This file contains 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
height: 0; overflow: hidden; padding-top: 20px; |
This file contains 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 | |
tail -n +2 $1 | split -l 10000 - split_ | |
for file in split_* | |
do | |
head -n 1 $1 > tmp_file | |
cat $file >> tmp_file | |
mv -f tmp_file output/$file.csv | |
rm $file | |
done |
This file contains 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
" Specify a directory for plugins (for Neovim: ~/.local/share/nvim/plugged) | |
call plug#begin('~/.vim/plugged') | |
" Make sure you use single quotes | |
" Shorthand notation; fetches https://github.com/junegunn/vim-easy-align | |
Plug 'junegunn/vim-easy-align' | |
" On-demand loading | |
Plug 'scrooloose/nerdtree', { 'on': 'NERDTreeToggle' } |
This file contains 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
find . -name '*.txt' -print0 | xargs -0 wc -l |
This file contains 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
{ | |
"coupon_id": { | |
// representer solo tiene format e includes_control | |
"representer": { | |
"format": "ean_13", // posible valores 'ean_13', 'code_25_interleaved', 'code_39', 'code_128' | |
"includes_control": true // posibles valores true/false | |
}, | |
// formater tiene max_size, prefix y format |