Skip to content

Instantly share code, notes, and snippets.

@michaelspiss
michaelspiss / connect-easysmx-controller.sh
Last active December 9, 2023 16:54
Connect (multiple) EasySMX controller(s) on linux
#! /bin/bash
IFS=: read -r busnum devnum <<< "$1"
busnum=$(printf "%03i" $busnum)
devnum=$(printf "%03i" $devnum)
xboxdrv --device-by-path ${busnum}:${devnum} --type xbox360 --silent --force-feedback
@kazlauskis
kazlauskis / mdb2sqlite.sh
Created September 8, 2016 13:26
Transforms MS Access MDB file to sqlite database using mdbtools
#!/bin/bash
# Inspired by
# https://www.codeenigma.com/community/blog/using-mdbtools-nix-convert-microsoft-access-mysql
# USAGE
# Rename your MDB file to migration-export.mdb
# run ./mdb2sqlite.sh migration-export.mdb
# wait and wait a bit longer...
mdb-schema migration-export.mdb sqlite > schema.sql
@ericremoreynolds
ericremoreynolds / bisect_key.py
Last active August 9, 2022 20:44
Key-like functionality recipe for Python's bisect functions
class KeyifyList(object):
def __init__(self, inner, key):
self.inner = inner
self.key = key
def __len__(self):
return len(self.inner)
def __getitem__(self, k):
return self.key(self.inner[k])
@XVilka
XVilka / TrueColour.md
Last active March 24, 2024 11:07
True Colour (16 million colours) support in various terminal applications and terminals

THIS GIST WAS MOVED TO TERMSTANDARD/COLORS REPOSITORY.

PLEASE ASK YOUR QUESTIONS OR ADD ANY SUGGESTIONS AS A REPOSITORY ISSUES OR PULL REQUESTS INSTEAD!