Skip to content

Instantly share code, notes, and snippets.

View jon-heller's full-sized avatar

Jon Heller jon-heller

View GitHub Profile
@jon-heller
jon-heller / Zoom.ahk
Created April 13, 2020 21:12
Zoom global hotkeys for Windows using AutoHotKey
; A system-wide mute toggle for Zoom Meetings.
$NumpadAdd::
; Zoom appears not to accept ControlSend when in the background, so
; we isolate the Zoom and current windows, switch over to Zoom, send
; its own mute-toggle hotkey, and then switch back.
;
; Get the current window
WinGet, active_window, ID, A
;

Keybase proof

I hereby claim:

  • I am jon-heller on github.
  • I am jonheller (https://keybase.io/jonheller) on keybase.
  • I have a public key ASA9mEMO12937PoT9NIKebqY5KV0I54obazcHKKbb9xYrAo

To claim this, I am signing this object:

@jon-heller
jon-heller / test-branch.sh
Created September 20, 2017 14:46
BackstopJS script to check out and test a branch against development
#!/bin/bash
git diff-index --quiet HEAD -- &>/dev/null
if [ $? -ne 0 ]; then
echo "Git status isn't clean! Please commit all changes first"
exit 1
fi
echo "Checking out development..."
git checkout development &>/dev/null
|I|18:18:41.048| *** Starting HSTracker/0.18.1.1297; (enUS;en;macOS 10.11.6) ***
|I|18:18:41.092| Opening trackers
|I|18:18:42.467| Fetching https://raw.githubusercontent.com/HearthSim/HSTracker/master/hs-build-dates.json complete
|I|18:18:42.476| Latest build : 15181, actual is 15181
|V|18:18:42.476| json file : /Users/Jon/Library/Application Support/HSTracker/json/cardsDB.enUS.json
|I|18:18:43.555| Loading decks
|E|18:18:43.565| Can not save backup : Error Domain=NSCocoaErrorDomain Code=516 "“hstracker.realm” couldn’t be copied to “HSTracker” because an item with the same name already exists." UserInfo={NSSourceFilePathErrorKey=/Users/Jon/Library/Application Support/HSTracker/hstracker.realm, NSUserStringVariant=(
Copy
), NSDestinationFilePath=/Users/Jon/Library/Application Support/HSTracker/hstracker.realm.backup, NSFilePath=/Users/Jon/Library/Application Support/HSTracker/hstracker.realm, NSUnderlyingError=0x7ff8d8d16420 {Error Domain=NSPOSIXErrorDomain Code=17 "File exists"}}
|I|18:18:43.606| Loading
@jon-heller
jon-heller / functions.php
Last active March 28, 2016 01:15
WordPress Read More
<?php
add_action('wp_ajax_nopriv_listing_load_more', 'listing_load_more');
add_action('wp_ajax_listing_load_more', 'listing_load_more');
function listing_load_more()
{
$next_page = $_POST['curPage']+1
// this is where you put your code to get more posts.
// it's just a normal wp_query but you pass in the current page number from
@jon-heller
jon-heller / README.md
Last active August 29, 2015 14:15 — forked from oodavid/README.md

Backup MySQL to Amazon S3

This is a simple way to backup your MySQL tables to Amazon S3 for a nightly backup - this is all to be done on your server :-)

Sister Document - Restore MySQL from Amazon S3 - read that next

1 - Install s3cmd

this is for Centos 5.6, see http://s3tools.org/repositories for other systems like ubuntu etc