Skip to content

Instantly share code, notes, and snippets.

@earthmeLon
earthmeLon / Baron_Marios_Turtle_Battle.mkd
Created December 15, 2023 16:18
Baron Mario's Turtle Battle

In the heart of a dense, ancient forest, there lived a fearsome Baron named Mario. With his towering stature, fire-red armor, and piercing brown eyes, he commanded an air of authority that sent shivers down the spines of even the bravest knights. Legends whispered of his unmatched strength, his ability to cleave through flesh and bone with a single swing of his mighty sword.

One fateful day, while Mario was traversing the forest on his trusty steed, he stumbled upon a clearing bathed in an ethereal glow. In the center stood a colossal turtle, its shell shimmering with an iridescent light. The creature's eyes, wise and ancient, met Mario's gaze, and an unspoken challenge hung in the air.

Undeterred by the turtle's imposing presence, Mario dismounted his steed and drew his sword, its blade gleaming ominously under the dappled sunlight. The turtle, unfazed by the Baron's weapon, extended a gnarled claw, its razor-sharp tip glinting menacingly.

With a thunderous roar, Mario charged forward, his sword poised to

@earthmeLon
earthmeLon / HorizonXI-Lutris.yaml
Last active February 15, 2023 17:44
Lutris Installer for HorizonXI
# Working Launcher for installation: 1.0.1
# Current Version of Launcher: $VERSION
# There are issues using newer launcher to install the game
# Instead, we grab the 1.0.1 installer to download and install the game
# After installation, switch Game Settings to load the current version of the launcher (ie: 1.1.3)
# Original: https://github.com/sarca571ca/horizonxi-lutris
name: HorizonXI
game_slug: horizonxi
@earthmeLon
earthmeLon / SetUnsetPublishTagToLabelValue
Last active June 20, 2021 03:29
What a bunch of bullshit, Traktor.
#!/bin/bash
# @earthmeLon
unset x
unset y
x="$(metaflac "$1" --show-tag=PUBLISHER| sed -rn 's/PUBLISHER=(.*)[\;]*/\1/p' )"
# Only take the first value, since Traktor doesn't support multi-value tags AT ALL.
y="$(metaflac "$1" --show-tag=LABEL| sed -rn 's/LABEL=(.*)[\;]*/\1/p' )"
@earthmeLon
earthmeLon / gist:36f0e6ad43b20f4a552db8242bc195b3
Created April 18, 2021 21:35
CRITICAL:whipper.command.main:missing dependency "cd-paranoia"
$ whipper drive analyze
CRITICAL:whipper.command.main:missing dependency "cd-paranoia"
$ sudo ln -sf /usr/bin/cdparanoia /usr/bin/cd-paranoia
@earthmeLon
earthmeLon / ThunarOpensDirectories.sh
Created April 16, 2021 17:55
Set Thunar to be default application for Directories (all, but ArchLinux)
xdg-mime default thunar.desktop inode/directory
@earthmeLon
earthmeLon / YouTubeQuery.sh
Created April 16, 2021 17:52
Deadbeef - Search Yoube
echo %artist% - %title% | perl -MURI::Escape -ne 'chomp;print uri_escape($_),"\n"' | \
xargs -0 -I {} -i bash -c "xdg-open https://youtube.com/results?search_query={}"
@earthmeLon
earthmeLon / picard_tagger_gone.mkd
Created April 1, 2021 20:59
Fix Picard "TAGGER" icon missing from MusicBrainz

Append ?tport=8000 to your MusicBrainz URL. Port 8000 is the default, which could be changed in Picard's Advanced > Network options .

@earthmeLon
earthmeLon / 70-fxpak.rules
Last active December 24, 2020 01:08
udev rules for FXPak
# /etc/udev/rules.d/70-fxpak.rules
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1209", ATTRS{idProduct}=="5a22", MODE="0666"
@earthmeLon
earthmeLon / minecraft-latest-download.sh
Created December 9, 2020 19:19
Determine and download latest Minecraft Server
function minecraft-latest-download(){
export MINECRAFT_MANIFEST=$(curl -s https://launchermeta.mojang.com/mc/game/version_manifest.json)
export MINECRAFT_LATEST=$(echo "${MINECRAFT_MANIFEST}" | jq .latest.release)
export MINECRAFT_LATEST_VERSION=$(echo "${MINECRAFT_MANIFEST}" | jq -r .latest.release)
export MINECRAFT_LATEST_URL=$(echo "${MINECRAFT_MANIFEST}" | jq -r ".versions[] | select(.id==${MINECRAFT_LATEST}).url")
export MINECRAFT_SERVER_JAR=$(curl -s ${MINECRAFT_LATEST_URL} | jq -r .downloads.server.url)
echo "Retrieving $MINECRAFT_LATEST_VERSION from $MINECRAFT_SERVER_JAR"
curl ${MINECRAFT_SERVER_JAR} --output minecraft-$MINECRAFT_LATEST_VERSION-server.jar
}
@earthmeLon
earthmeLon / rgb_xy
Last active February 27, 2020 23:28
Translate RGB colour to XY for HUE Lights
#!/usr/bin/env python3
def rgb_xy(red, green, blue):
red = int(red, 16)
green = int(green, 16)
blue = int(blue, 16)
x = round((red * 0.649926 + green * 0.103455 + blue * 0.197109), 6)
y = round((red * 0.234327 + green * 0.743075 + blue * 0.022598), 6)
z = round((red * 0.0000000 + green * 0.053077 + blue * 1.035763), 6)