Skip to content

Instantly share code, notes, and snippets.


Michael Holler mikeholler

View GitHub Profile
View gist:f9fc17f45fd848a01a9de91950c533f8
import asyncio
import datetime as dt
import logging
import os
import pyracing
import sys
from pyracing.client import Client
from pyracing.response_objects.chart_data import IRating
from pyracing.constants import ChartType
from pyracing.constants import Category
mikeholler /
Created Jan 8, 2020
Require keyword or positional arguments for Python dataclasses
from dataclasses import is_dataclass
from typing import TypeVar, Type, Callable, List, Dict, Any
_T = TypeVar("_T")
_Self = TypeVar("_Self")
_VarArgs = List[Any]
_KWArgs = Dict[str, Any]
def _kwarg_only_init_wrapper(
mikeholler / antora-generate-wrapper.js
Created Sep 12, 2019
Wrapper that allows for --author-mode argument.
View antora-generate-wrapper.js
#!/usr/bin/env node
* This is a wrapper to the `antora generate` command line tool that adds some
* functionality not otherwise present in antora.
* Before getting into that, one restriction is that the playbook.yml file MUST
* be the first argument to this command, otherwise this script will not work
* correctly. Other than that small restriction, all other uses of
* `antora generate` are supported here.
mikeholler /
Created Nov 21, 2014
Profiling String Comparison vs. Class.isAssignableFrom(...) Comparison.
import java.util.Collection;
import java.util.List;
import java.util.Scanner;
public final class Scratch {
public static final String CORRECT_CLASS_NAME = List.class.getCanonicalName();
public static final String INCORRECT_CLASS_NAME = Scanner.class.getCanonicalName();
View UML Diagramming
Cheat sheet for UML diagramming: From
public class DatabaseHelper extends OrmLiteSqliteOpenHelper
private static DatabaseHelper instance;
public static synchronized DatabaseHelper getHelper(Context context)
if (instance == null)
instance = new DatabaseHelper(context);
return instance;
View .vimrc
" URL:
" Authors:
" Description: A minimal, but feature rich, example .vimrc. If you are a
" newbie, basing your first .vimrc on this file is a good choice.
" If you're a more advanced user, building your own .vimrc based
" on this file is still a good idea.
" Features {{{1
git tag -d 12345
git push origin :refs/tags/12345
mikeholler /
Created Feb 10, 2014
A list of Android libraries.


  • Otto event bus.
  • Picasso image downloading and caching library.
mikeholler /
Created Feb 10, 2014
Create a screen cast GIF in Ubuntu.

First install this:

sudo apt-get install imagemagick mplayer gtk-recordmydesktop

those are the required stuff, ImageMagick, MPlayer and Desktop Recorder. Then use Desktop Recorder to capture a portion of the screen/application to use as the screencast. After the Desktop Recorder has saved the recording into an OGV video, MPlayer will be used to capture JPEG screenshots, saving them into the 'output' directory.

On a terminal:

You can’t perform that action at this time.