Skip to content

Instantly share code, notes, and snippets.

@romanmah
romanmah / redis-mygrate.py
Created March 20, 2014 14:03
A small utility for redis db migration
#!/usr/bin/python
import redis
import pickle
import argparse
class RedisMigrate():
def __init__(self, host, port, db):
@romanmah
romanmah / sql test
Created September 12, 2014 23:00
test 1
{
// Your GitHub API token
// see: https://github.com/condemil/Gist#generating-access-token
"token": "c1d400e8fa22a571f280a22ca0db0001fe625aa3",
// Show the authors of Gists
"show_authors": false,
}
@romanmah
romanmah / kernel_to_utc.sh
Created February 1, 2015 14:31
Convert kernel time to utc
#!/bin/env bash
ut=`cut -d' ' -f1 </proc/uptime`
ts=`date +%s`
date -d"70-1-1 + $ts sec - $ut sec + $1 sec" +"%F %T"