Skip to content

Instantly share code, notes, and snippets.

View nicktimko's full-sized avatar

Nick Timkovich nicktimko

View GitHub Profile
@nicktimko
nicktimko / awsome_operator.py
Last active May 14, 2018 14:20
python arbitrary binary operators
import functools
class Operator:
def __init__(self, func):
self.func = func
def __rlshift__(self, other):
return self.__class__(functools.partial(self.func, other))
def __rshift__(self, other):
@nicktimko
nicktimko / Passwords.ipynb
Created February 25, 2018 00:28
Manual Password Cracking from the 500M list
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@nicktimko
nicktimko / app.py
Created February 16, 2018 02:12
py 101 feb 15
from __future__ import unicode_literals
import sys
import statistics
from prompt_toolkit import prompt, AbortAction
from prompt_toolkit.history import InMemoryHistory
from prompt_toolkit.contrib.completers import WordCompleter
import meetup.api
def get_names():
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@nicktimko
nicktimko / XvX.ipynb
Last active January 20, 2018 01:56
This or That?
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@nicktimko
nicktimko / DaBeazStrings.ipynb
Created November 7, 2017 22:18
Python String Tutorial
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
commit e951eec402172028c7dfa4354f5664af2eb73203
Author: Nick Timkovich <npt@uchicago.edu>
Date: Fri Aug 4 12:33:29 2017 -0500
Use specified phrases in lieu of 'Used' for limit summary
diff --git a/horizon/templates/horizon/common/_limit_summary.html b/horizon/templates/horizon/common/_limit_summary.html
index b58ba8b4c..251d98b6b 100644
--- a/horizon/templates/horizon/common/_limit_summary.html
+++ b/horizon/templates/horizon/common/_limit_summary.html
@nicktimko
nicktimko / override_guard.ipynb
Last active November 25, 2016 19:43
Override Checking
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@nicktimko
nicktimko / mycnf.py
Created November 11, 2016 19:29
MySQL/MariaDB Python configuration reader
from __future__ import print_function, unicode_literals
import os
import codecs
import glob
import logging
import stat
CP_MODERN = True
try:
import configparser
@nicktimko
nicktimko / chipy_dojo.py
Created October 21, 2016 01:13
ChipyDojo
import cmd
import textwrap
from collections import Counter
dungeon = {
(2, 1): 'hat',
(2, 2): 'goblin',
(2, 4): 'machete',
}
no_opponent = "The Goblin isn't available"