Skip to content

Instantly share code, notes, and snippets.

Leigh McCulloch leighmcculloch

Block or report user

Report or block leighmcculloch

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
View keybase.md

Keybase proof

I hereby claim:

  • I am leighmcculloch on github.
  • I am stellarleigh (https://keybase.io/stellarleigh) on keybase.
  • I have a public key ASA8ZwWJURiHXB-6uoy8wuCtH12Cp2h8DENyFOLKtp81iQo

To claim this, I am signing this object:

View keybase.md

Keybase proof

I hereby claim:

  • I am leighmcculloch on github.
  • I am leighmcculloch (https://keybase.io/leighmcculloch) on keybase.
  • I have a public key ASAlVil3fPHev_c0Qh8XWZyTWSY3zD8gvCzVA9Ez-DFdTwo

To claim this, I am signing this object:

View keybase.md

Keybase proof

I hereby claim:

To claim this, I am signing this object:

@leighmcculloch
leighmcculloch / minimal-arq-aws-policy.json
Created Dec 24, 2017
Minimal AWS IAM policy for ARQ.
View minimal-arq-aws-policy.json
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "0",
"Effect": "Allow",
"Action": ["s3:ListAllMyBuckets", "s3:ListObjects"],
"Resource": "*"
},
{
@leighmcculloch
leighmcculloch / install-neovim.sh
Last active Jul 14, 2017
This gist will on ubuntu/xenial64 (16.04) will install Neovim with python3 (needed for some modules) and install my config. This install is pulled out of my larger devenv setup which can be found at https://github.com/leighmcculloch/devenv. This install assumes Go is already installed.
View install-neovim.sh
# Install Neovim
sudo add-apt-repository -y ppa:neovim-ppa/stable
sudo apt-get update
sudo apt-get install -y neovim
# Install git
sudo apt-get install git
# Install python3 for Neovim python modules
sudo apt-get install -y python-dev python-pip python3-dev python3-pip
@leighmcculloch
leighmcculloch / mfa-delete-execute.rb
Created Nov 7, 2015
A simple tool that will help you delete files on buckets with MFA Delete feature enabled.
View mfa-delete-execute.rb
#!/usr/bin/env ruby
require 'aws-sdk'
print "AWS Account ID: "
aws_account_id = STDIN.gets.chomp
print "S3 bucket name: "
bucket_name = STDIN.gets.chomp
print "AWS Access Key ID: "
aws_id = STDIN.gets.chomp
print "AWS Access Secret Key: "
@leighmcculloch
leighmcculloch / mfa-delete-enable.rb
Last active Nov 7, 2015 — forked from petethepig/mfa-delete.rb
A simple tool that will help you enable MFA Delete feature on your S3 bucket
View mfa-delete-enable.rb
#!/usr/bin/env ruby
require 'aws-sdk-v1'
print "S3 bucket name: "
bucket_name = STDIN.gets.chomp
print "AWS Access Key ID: "
aws_id = STDIN.gets.chomp
print "AWS Access Secret Key: "
aws_key = STDIN.gets.chomp
print "AWS Root MFA Serial: "
@leighmcculloch
leighmcculloch / mdig.rb
Created Aug 20, 2014
Multi-Region DNS Lookup Utility
View mdig.rb
# Multi-Region DNS NameServer Propogation Check
#
# Uses the dns-lg.com API to retrieve the NS records for a zone (domain name)
# at 19 (more or less) different locations globally. Use this to monitor the
# propogation of nameserver changes at your registrar.
#
# Note: There is no such thing as a guarantee when it comes to whether your
# new nameservers have propogated fully or not. Rule of thumb is three days
# but often it is much faster and this check can help you weigh the risks.
@leighmcculloch
leighmcculloch / Android Screenshot.bat
Created Dec 5, 2013
This batch script will take a screenshot on an Android device using ADB, download the screenshot to the directory this script to the current directory and then remove the screenshot file from the device. Screenshots are saved with filename: screenshot-YYYYMMDD-HHMMSS.png. ADB must be connected to a device already.
View Android Screenshot.bat
@echo off
rem configurable parameters
set SCREENCAP_FILE_PREFIX=screenshot
rem the dir on the device where the screenshot will be stored temporarily
set SCREENCAP_WORKING_DIR=/sdcard/
rem adb path, leave blank if adb is already on the user or system path
set SCREENCAP_ADB_PATH=
You can’t perform that action at this time.