This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Should we connect via IPv4 or IPv6? | |
if ping -c 1 ipv6.google.com &> /dev/null | |
then | |
SERVER="tron6" | |
else | |
SERVER="tron" | |
fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Quick and dirty script to remove spam domains from our mandrill account | |
define('API_KEY', ''); | |
// Their API doesn't offer a "delete" method, so I'm using their website | |
define('USERNAME', ''); | |
define('PASSWORD', ''); | |
echo 'Downloading domain list...'; | |
// Step 1, get all "sending domains" via their API | |
$jsonKey = json_encode(['key' => API_KEY]); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# This script uses dislocker-fuse to mount bitlocker'd flash drives | |
# First off, we need to know the drive to mount. | |
# For now, it'll need to be passed. Maybe in the future, we can use dislocker-find or something. | |
# Anyway, we need to get its recovery key, so we can check to see if we have it saved. | |
KEYS=$(sudo dislocker-metadata -V $1 | grep 'Recovery Key GUID' | grep -Eo "'.+'") | |
# http://stackoverflow.com/a/15400047 | |
KEYARRAY=(${KEYS// / }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#compdef emergeTools | |
# This is a zsh autocomplete file for NTICompass' "emergeTools" script | |
_emergeTools(){ | |
local -a commands | |
commands=( | |
'update: Update emerge''s database' | |
'upgrade: List available package updates' | |
'safe-upgrade: Run upgrade WITHOUT --keep-going' | |
'check: [deprecated] Run revdep-rebuild' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/env python3 | |
""" | |
PyLocker: A python program to do stuff with BitLocker drives & files. | |
bek_file.py: Prints info about BEK files (startup keys) | |
""" | |
import struct, binascii | |
# filestimes.py from http://reliablybroken.com/b/2009/09/working-with-active-directory-filetime-values-in-python/ | |
from filetimes import filetime_to_dt |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- https://forum.manjaro.org/t/conky-thread-show-your-work/2951/326 | |
conky.config = { | |
use_xft = true, | |
xftalpha = 0.8, | |
update_interval = 1.0, | |
total_run_times = 0, | |
own_window = true, | |
own_window_transparent = true, | |
own_window_argb_visual = true, | |
own_window_type = 'normal', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/env python3 | |
""" | |
Brute-force solver for a math toy/puzzle | |
©1993 Silver Star | |
""" | |
import operator | |
from itertools import product | |
from collections import deque |
OlderNewer