Skip to content

Instantly share code, notes, and snippets.

View kxseven's full-sized avatar

Hugh Mooney kxseven

View GitHub Profile
@kxseven
kxseven / pihole.blacklist
Last active August 13, 2024 06:41
pihole.blacklist
# Block Spotify Ads
media-match.com
adclick.g.doublecklick.net
www.googleadservices.com
# open.spotify.com
pagead2.googlesyndication.com
desktop.spotify.com
googleads.g.doubleclick.net
pubads.g.doubleclick.net
securepubads.g.doubleclick.net
@kxseven
kxseven / cloudSettings
Created October 30, 2018 09:13
Visual Studio Code Settings Sync Gist
{"lastUpload":"2018-10-30T09:13:07.934Z","extensionVersion":"v3.2.0"}
@kxseven
kxseven / gist:5ed79783e73fb464b93393c1f1e2477d
Last active November 10, 2017 09:37
musizbrainz-picard-naming
$if(
$eq(
%musicbrainz_albumartistid%,89ad4ac3-39f7-470e-963a-56509c546377),
$left($if2(%albumartistsort%,%artistsort%),30)
/
$left(%album%,40) [$if(%date%,$left(%date%,4))]
/
$left(%album%,30) - $if($gt(%totaldiscs%,1),$if2(%media%,CD)%discnumber%-,)$num(%tracknumber%,2)-$left(%title%,30),
$upper($firstalphachar($if2(%albumartistsort%, %artistsort%),#))
/
@kxseven
kxseven / ssh-host-rip.bash
Created August 24, 2017 15:35
Helper script to remove SSH fingerprints from your known-hosts
#!/usr/bin/env bash
##############################################################################
# Shell Behaviour
##############################################################################
# Check for unbound variables being used
# set -o nounset
# Exit is a bad command is attempted. If you're going to handle errors then
@kxseven
kxseven / survivor.py
Last active June 2, 2017 15:17
Soldiers Survivor
#!/usr/bin/ython
# Scenario:
# - A group of soldiers is captured and have all agreed to
# kill themselves to prevent being tortured for the infomration
# they possess.
# - They will form a circle and count out loud together, killing
# someone from the circle each time their position in the circle
# is divisible by a number until only one is left, upon which that
# last person must kill themselves
# - One of the soldiers has figured out a way to escape alive but
https://cdn.winscp.net/files/winscp576.zip?secure=x00qUEV536pMixRHGxdXxQ==,1453388727
@kxseven
kxseven / knife.rb
Last active August 29, 2015 14:24 — forked from mpasternacki/knife.rb
# knife.rb config snippet to make knife ssh command use your own login
# instead of hard-coded `root', `ubuntu' or other name. Tries to get
# login for your domain from ~/.ssh/config and if it's not found
# there, uses your local login.
require 'net/ssh'
require 'etc'
knife[:ssh_user] =
Net::SSH::Config.for('some.host.inside.your.domain')[:user] ||
# Install dependencies
sudo apt-get install liblxc1 lxc-dev libclxclient-dev
# Install Chef Provisioning
chef gem install chef-provisioning
# Install plugins for Chef Provisioning
chef gem install chef-provisioning-vagrant
chef gem install chef-provisioning-aws
chef gem install chef-provisioning-azure