Skip to content

Instantly share code, notes, and snippets.

Nick Bair njbair

Block or report user

Report or block njbair

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
njbair /
Created Nov 29, 2013
Sets a Cache-Control HTTP header on all matching objects in an Amazon S3 bucket
# Amazon S3 Cache-Control Processor
# Programmatically applies the specified Cache-Control metadata to all
# matching objects (files) in an S3 bucket
# Uses the excellent boto library <>
njbair / html-markup-shortcodes.php
Created Feb 21, 2015
Custom HTML WordPress Shortcode - add any HTML tag in the WYSIWYG editor!
View html-markup-shortcodes.php
* by Nick Bair
* This is a nice little cheater shortcode for devs who don't want the WordPress
* WYSIWYG editor to strip out their HTML tags.
njbair /
Last active Sep 11, 2015
Setting up a base Debian installation as a generic build environment

HOWTO: Debian Build Box

This is a quick how-to on setting up a fresh Debian installation as a multi-purpose build environment. By fresh installation, we're talking about a bare-bones netinst with all installation tasks unchecked. If you choose to install standard system utilities, many of these packages will already be installed.

First, login as a standard user, then issue the su command to elevate to root:

$ su

Install Some Software

njbair /
Last active Apr 4, 2019
Use these CPUID flags to trick your Windows 7 VirtualBox VM into thinking your AMD Ryzen is an AMD A8-5600K.
vboxmanage modifyvm "Windows 7" --cpuidset 00000000 0000000d 68747541 444d4163 69746e65
vboxmanage modifyvm "Windows 7" --cpuidset 00000001 00610f01 01040800 3e98320b 178bfbff
vboxmanage modifyvm "Windows 7" --cpuidset 00000002 00000000 00000000 00000000 00000000
vboxmanage modifyvm "Windows 7" --cpuidset 00000003 00000000 00000000 00000000 00000000
vboxmanage modifyvm "Windows 7" --cpuidset 00000004 00000000 00000000 00000000 00000000
vboxmanage modifyvm "Windows 7" --cpuidset 00000005 00000040 00000040 00000003 00000000
vboxmanage modifyvm "Windows 7" --cpuidset 00000006 00000000 00000000 00000001 00000000
vboxmanage modifyvm "Windows 7" --cpuidset 00000007 00000000 00000008 00000000 00000000
njbair / docker-compose.yml
Created Mar 14, 2019
WordPress, MySQL 5.7, Adminer for Local Dev
View docker-compose.yml
version: '3.1'
image: wordpress
- 80:80
njbair / yourls-plugin-users-in-database.php
Created Feb 13, 2020
YOURLS Store Users in Database
View yourls-plugin-users-in-database.php
Plugin Name: Users in Database
Plugin URI:
Description: Puts users in the database
Version: 1.0
Author: Nick Bair
Author URI:
You can’t perform that action at this time.