Skip to content

Instantly share code, notes, and snippets.

View wlizama's full-sized avatar
💻
Making amazing things 🔣

Wilder Lizama wlizama

💻
Making amazing things 🔣
View GitHub Profile
import fnmatch
import os
MY_DIR = 'Q:\\my_dir\\sub_dir'
FILE_EXT = 'xml'
def filter_files_by_ext(dir, filter_ext):
files = [file for file in os.listdir(dir) if fnmatch.fnmatch(file, '*.%s' % filter_ext)]
return files
from os import listdir
from os.path import isfile, join
MY_DIR = 'Q:\\midir'
def execute():
onlyfiles = [f for f in listdir(MY_DIR) if isfile(join(MY_DIR, f))]
print(onlyfiles)
git config --global alias.superlog "log --graph --abbrev-commit --decorate --date=relative --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(reset)%C(bold yellow)%d%C(reset)' --all"
// GLOBALS
//Array of file extension which you would like to extract to Drive
var fileTypesToExtract = ['pdf', 'xml'];
//Name of the folder in google drive i which files will be put
var folderName = 'LabelMOD';
//Name of the label which will be applied after processing the mail message
var labelName = 'LabelMOD';
@wlizama
wlizama / cookieModificar.js
Last active May 4, 2018 22:53
Modificar cookies
javascript:void prompt("Introduce la cookie:",document.cookie).replace(/[^;]+/g,function(_){document.cookie=_;});