I hereby claim:
- I am oslerw on github.
- I am librewulf (https://keybase.io/librewulf) on keybase.
- I have a public key ASA32GCGkcE0q6Got_sIFj_lp7TA4CEYvP4NdmfQbyw1PQo
To claim this, I am signing this object:
#!/bin/sh | |
set -e | |
set -u | |
if [ "$2" = "up" ]; then | |
if [ "$CONNECTION_ID" = "GSR-WIFI" ]; then | |
sleep 3; | |
curl 'http://guest.grandsierraresort.com/login.html' -X POST -H 'Content-Type: application/x-www-form-urlencoded' -H 'Origin: http://gsr-wifi.com' -H 'Referer: http://gsr-wifi.com/' --data-raw 'buttonClicked=4&redirect_url=https%3A%2F%2Fwww.grandsierraresort.com&err_flag=0' -o /dev/null -s; | |
fi |
#!/bin/env ruby | |
# | |
# HOW TO USE THIS SCRIPT | |
# | |
# From keepass, export an XML file, put it in this directory named "foo.xml" | |
# | |
# Then, sign in to the op client: eval $(op signin DOMAIN) | |
# |
I hereby claim:
To claim this, I am signing this object:
#!/bin/bash | |
# | |
# For when you have a one sided-feed scanner, but need to scan a bunch of | |
# double sided pages. To use: | |
# 1. Scan the pages normally, so that the odd side of page 1 is scanned first. | |
# 2. Pick up the stack of papers from the tray, *without flipping them*, | |
# such that the even side of the last page gets scanned first | |
# 3. Run this script on it | |
# | |
# Requires pdftk |
#!/bin/env ruby | |
require 'matrix' | |
SUDOKU_FILE = './sudoku/solution.txt' | |
MATRIX_DIM = 3 | |
COL_OFFSET = 3 | |
ROW_OFFSET = 3 | |
def letter_to_num(letter) |
#!/bin/env ruby | |
cipher = File.read('ciphertext.txt') | |
letters = Hash.new do 0 end | |
cipher.each_char do |c| | |
letters[c] += 1 | |
end |
#!/bin/env ruby | |
input = File.read('./puzzle.txt') | |
rows = input.split("\n") | |
rows.each_index do |row| | |
rows[row].split('').each_index do |column| | |
if rows[row][column] != '_' | |
print row + 1 |
#!/usr/bin/env ruby | |
# This script checks CVG's website, scraping their TSA checkpoint time estimate | |
# so that you can watch it to figure out when to leave to catch a flight. | |
require 'open-uri' | |
require 'nokogiri' | |
while (true) | |
html = Nokogiri::HTML(open('https://www.cvgairport.com/')) |
# contains(string, substring) | |
# | |
# Returns 0 if the specified string contains the specified substring, | |
# otherwise returns 1. | |
# Taken from https://stackoverflow.com/questions/2829613/how-do-you-tell-if-a-string-contains-another-string-in-unix-shell-scripting/8811800#8811800 | |
contains() { | |
string="$1" | |
substring="$2" | |
if test "${string#*$substring}" != "$string" | |
then |
#! /usr/bin/perl -w | |
# | |
# This script gets the currently playing album via MPRIS2/DBus and then sets | |
# the wallpaper accordingly. Requires feh to set the background. This may not | |
# work if your desktop environment manages the background in some special way. | |
# | |
# The script searches first for files containing the following (in order): | |
# - background | |
# - wallpaper | |
# - cover |