Skip to content

Instantly share code, notes, and snippets.

View mrmanc's full-sized avatar

Mark Crossfield mrmanc

View GitHub Profile
@mrmanc
mrmanc / whisper-calculator.py
Last active October 6, 2015 15:40 — forked from jjmaestro/whisper-calculator.py
whisper-calculator.py:Calculates the size of the whisper storage for the given retention (in frequency:history format)
#!/usr/bin/env python
# -*- coding: utf-8 -*-
def archive_to_bytes(archive):
def to_seconds(s):
SECONDS_IN_A = {
's': 1,
'm': 1 * 60,
'h': 1 * 60 * 60,