Skip to content

Instantly share code, notes, and snippets.

View mxlian's full-sized avatar

Maximiliano mxlian

View GitHub Profile
"""
a simple stop loss bot.
adjust STOP_PRICE and STOP_VOLUME to your needs.
The file can be reloaded after editing without
restarting goxtool by simply pressing the l key.
"""
import strategy
import goxapi
# pylint: disable=C0301
@mxlian
mxlian / install_hack_typeface.sh
Created September 1, 2015 09:00
Install Hack Typeface on Ubuntu/Debian
DEST_DIR=~/.fonts/hack_typeface
mkdir -p $DEST_DIR
# Check if you have unzip, if not install
which unzip >/dev/null || (echo "INFO: I need to install unzip"; sudo apt-get install unzip)
# Download font
wget --directory-prefix $DEST_DIR https://github.com/chrissimpkins/Hack/releases/download/v2.010/Hack-v2_010-otf.zip
# Decompress
unzip $DEST_DIR/Hack-*.zip -d $DEST_DIR
# Clean zip file
@mxlian
mxlian / gist:2ab6810d0e64cf05f9f5cc298614bca0
Created September 5, 2021 17:04
Fix kernel / grub with LUKS crypted partition
# Mounting the LUKS partition is critical, as the name that should be used should match /etc/crypttab in order
# for the rest of the toolchain to work properly
cryptsetup luksOpen /dev/nvme0n1p6 nvme0n1p6_crypt # <-- pay attention to this (should match /etc/crypttab or update-initramfs will fail
vgchange -ay # not sure if needed
lvscan # not sure if needed, no output
# mount FS
mount /dev/mapper/nvme0n1p6_crypt /mnt