Skip to content

Instantly share code, notes, and snippets.

View mm-pagely's full-sized avatar

Michael Martin mm-pagely

  • Pagely
View GitHub Profile
@mm-pagely
mm-pagely / split-users.awk
Last active December 13, 2016 16:07
Some awk-foo for splitting a mysql slow log up into individual user logs
#!/usr/bin/awk -f
BEGIN {
block = ""
}
{
line = $0
if (line ~ /^# User@Host/) {
@mm-pagely
mm-pagely / normalize.py
Last active December 16, 2016 20:45
Unicode Normalization Demo
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from __future__ import print_function
import urllib
import unicodedata
import sys
def normalized_urlencode(string, method):
'''