Skip to content

Instantly share code, notes, and snippets.

View stephenyeargin's full-sized avatar
:shipit:

Stephen Yeargin stephenyeargin

:shipit:
View GitHub Profile
@stephenyeargin
stephenyeargin / resume.json
Last active June 13, 2024 03:00
Source data for https://jsonresume.org/ templates
{
"$schema": "https://raw.githubusercontent.com/jsonresume/resume-schema/v1.0.0/schema.json",
"basics": {
"name": "Stephen Yeargin",
"label": "Sr. Software Engineer",
"image": "https://github.com/stephenyeargin.png",
"email": "stephen@yearg.in",
"phone": "(615) 829-6584",
"url": "https://stephenyeargin.com",
"summary": "Experienced software engineer leveraging diverse background in companies of varying sizes to drive business success through enterprise-grade, web-based applications. Dedicated to continuous growth, eager to expand skills in languages, frameworks, and technologies to optimize solutions for evolving challenges.",
@stephenyeargin
stephenyeargin / check_ssl.sh
Created June 21, 2020 17:50
Checks given domains (as arguments) for certificate expiration.
#!/usr/bin/env bash
domains=("$@")
for i in ${!domains[@]}; do
echo ${domains[$i]}
echo "" | openssl s_client -connect ${domains[$i]}:443 -servername ${domains[$i]} 2>/dev/null | openssl x509 -noout -enddate | sed -e 's/^notAfter\=//'
echo ""
done
@stephenyeargin
stephenyeargin / boxen-el-capitan
Created November 3, 2015 02:15
Fix boxen on El Capitan (OS X 10.11.1)
## Fix Gems
gem install bundler
bundle exec script/bootstrap
## Fix NGINX
# https://github.com/boxen/our-boxen/issues/778
brew link openssl --force
@stephenyeargin
stephenyeargin / roll-slack-webhooks.rb
Last active August 29, 2015 14:17
Roll Slack Webhooks
require 'octokit'
# Config
GITHUB_API_TOKEN = '<a token>'
GITHUB_ORGANIZATION = '<an organization>'
###
client = Octokit::Client.new(
access_token: GITHUB_API_TOKEN
@stephenyeargin
stephenyeargin / referer-spam.md
Last active August 31, 2018 13:41
NGINX referral spam blocking

Following this guide + data from this page

File: /etc/nginx/global/referer-spam.conf

##
# Referrer exclusions
##
if ($http_referer ~ "(buttons-for-website\.com|darodar\.com|econom\.co|ilovevitaly\.co|kambasoft\.com|lumb\.co|7makemoneyonline\.com|ranksonic\.info|savetubevideo\.info|see-your-website-here\.com|semalt\.com|priceg\.com|srecorder\.com|descargar-musica-gratis\.net|54\.186\.60\.77|lomb\.co)") {
  set $prohibited "1";

Keybase proof

I hereby claim:

  • I am stephenyeargin on github.
  • I am stephenyeargin (https://keybase.io/stephenyeargin) on keybase.
  • I have a public key whose fingerprint is B322 2906 77B2 8122 7AA6 6861 F1B6 17E7 B31A 06EA

To claim this, I am signing this object:

@stephenyeargin
stephenyeargin / pi-setup.md
Created November 11, 2014 06:15
General setup for my Raspberry Pi

Update the local install

$ sudo apt-get update
$ sudo apt-get upgrade

Update the firmware

@stephenyeargin
stephenyeargin / dewey-defeats-truman.md
Created October 1, 2014 05:09
MLB.com writer Dick Kaegel had no time for extra innings, so this one got filed early.

screenshot

Royals left feeling blue after rally comes up short

Ventura, in relief of Shields, gives up go-ahead, three-run HR in sixth

By Dick Kaegel / MLB.com | 9/30/2014 10:00 PM ET

KANSAS CITY -- A jammed-in crowd shook Kauffman Stadium with blue thunder, releasing its pent-up passion after 28 dry years, trying to push the Royals to another great moment in their return to postseason play. It didn't happen.

@stephenyeargin
stephenyeargin / remote-control-dashing.md
Last active April 27, 2017 11:41
Using Dashing with Hubot to control which dashboard is being shown.

Remotely control your Dashing Dashboard

The problem

We have a dashboard at the office that displays some internal company metrics so everyone can be up to speed on them. However, when we have guests, we have to either SSH into the Raspberry Pi or simply turn off the television. This seems clumsy, and we can do better than that.

The solution

Dashing works by adding event listeners in Javascript and updating the associated widgets. We're going to hijack this process to build a simple redirect that can accept a posted value and send the dashboard to another screen.

@stephenyeargin
stephenyeargin / README.md
Last active February 16, 2019 10:09
Add an Uber widget to your Dashboard

Uber Dashing Widget

This Dashing Dashboard widget allows you to see an estimate of how close the nearest Uber driver is to your location (in minutes). Useful if you're planning a fast getaway from the office.

screenshot

Before you get started

Go ahead and register an application with Uber. It is a relatively painless process if you already have an Uber account.