Skip to content

Instantly share code, notes, and snippets.

Jake Bathman jakebathman

Block or report user

Report or block jakebathman

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
jakebathman /
Last active Jun 29, 2018
IRC server setup on CentOS 7
# This sets the variable $IPADDR to the IP address the new Linode receives.
IPADDR=$(/sbin/ifconfig eth0 | awk '/inet / { print $2 }' | sed 's/addr://')
sudo yum update -y
sudo yum install nginx wget git -y
cd ~
jakebathman / scrape_ign_fortnite_map_tiles.php
Created May 10, 2018
Scrape the IGN Fortnite map tiles and re-construct a large map image
View scrape_ign_fortnite_map_tiles.php
If you have PHP installed, run this from the command line:
php scrape_ign_fortnite_map_tiles.php
jakebathman /
Created Apr 25, 2018
Random string generator
# Use these on the command line to generate random strings
# Tested in CentOS and macOS
# All printable characters
head /dev/urandom | LC_CTYPE=C tr -dc "[:print:]" | head -c 32
# Only A-Za-z0-9
head /dev/urandom | LC_CTYPE=C tr -dc "A-Za-z0-9" | head -c 32
# Alphanum with some special characters
jakebathman /
Last active Apr 20, 2018
Update a repo fork with the original (upstream)
# sync a fork using the upstream branch
if [ -z "$1" ]; then
jakebathman / remove_laravel_comments.php
Last active May 17, 2019
Remove comments from fresh Laravel files
View remove_laravel_comments.php
| Remove Laravel Comments
| Just made a new Laravel project, but don't want all those big
| comment blocks? Put this in the root of your project and run
| "php remove_laravel_comments.php"
jakebathman /
Created Feb 15, 2018
Determine if Backblaze is currently backing up files on macOS
# This will look at the overviewstatus.xml file and
# determine if Backblaze is currently transmitting a file.
# Developed against:
# macOS 10.13.3
# Backblaze
jakebathman / .tmux.conf
Last active Dec 14, 2017
Customizing tmux
View .tmux.conf
# Many of these customizations are from
# remap prefix from 'C-b' to 'C-a'
unbind C-b
set-option -g prefix C-a
bind-key C-a send-prefix
# split panes using | and -
bind | split-window -h
jakebathman /
Last active Jan 6, 2018
Various shell commands that I always have to look up
# Delete files based on a pattern
# The example below removes PDF files in nested directories, such as ./50/round_2/foo.pdf
# but would NOT remove the file ./50/packages/foo.pdf
find . -regextype posix-extended -regex ".*/round.*\.pdf" -exec rm {} +
# Delete a history item by its ID
history # get the ID (left-hand number) for the item you want to remove
history -d item_number
# Delete keys in redis matching some pattern, atomically
jakebathman /
Last active Sep 6, 2017
A list of HH QRP agencies in exempted counties from Hurricane Harvey

Hurricane Harvey QRS Exemptions

The list below (in three different formats) are for Home Health Agencies whose ZIP code intersects with one of the exempted counties or parishes in Texas and Louisians, as determined by CMS.

Full information about the exemption is here:

Additional updates on Hurricane-related exemptions is being posted by CMS here:

The agency data was pulled on September 6th, 2017 from the CMS website here:

jakebathman / arrayToTable.php
Created Aug 14, 2017
Make a quick HTML table from a PHP array
View arrayToTable.php
function arrayToTable(array $values, array $headers = [])
$options = [
'tableStyle' => 'border: 1px solid black;border-collapse: collapse;',
'thStyle' => 'border: 1px solid black;padding: 5px 7px;text-align: center;',
'tdStyle' => 'border: 1px solid black;padding: 5px 7px;text-align: center;',
$th = "<th style='" . $options['thStyle'] . "'>";
$td = "<td style='" . $options['tdStyle'] . "'>";
You can’t perform that action at this time.