Skip to content

Instantly share code, notes, and snippets.

View jbonhag's full-sized avatar
🌊

Jeff Bonhag jbonhag

🌊
  • America/New_York
View GitHub Profile
@alisdair
alisdair / intensify.sh
Created May 21, 2019 23:44
intensifies Slack emoji creator
#!/bin/bash
# Generate a `:something-intensifies:` Slack emoji, given a reasonable image
# input. I recommend grabbing an emoji from https://emojipedia.org/
set -euo pipefail
# Number of frames of shaking
count=10
# Max pixels to move while shaking
@repodevs
repodevs / macOS.sh
Created December 12, 2018 14:56
gpg: signing failed: Inappropriate ioctl for device macOS
❱ git config user.signingKey 38AF394C
❱ git config commit.gpgSign true
❱ echo "test" | gpg --clearsign
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
test
gpg: signing failed: Inappropriate ioctl for device
gpg: [stdin]: clear-sign failed: Inappropriate ioctl for device
(function() {
window.onerror = function(message, url, line, column) {
if (typeof url === "undefined" || url === null || url === "") {
return;
}
var data = JSON.stringify({
message: message,
url: url,
line: line,
@jbonhag
jbonhag / Makefile
Created January 2, 2017 01:22
Make a DVD from iPhone movies
all: clean dvd
dvd: dvd.iso
hdiutil burn dvd.iso
dvdauthor.xml:
echo "<dvdauthor>" > dvdauthor.xml
echo " <vmgm />" >> dvdauthor.xml
echo " <titleset>" >> dvdauthor.xml
echo " <titles>" >> dvdauthor.xml
@josephernest
josephernest / wavfile.py
Last active March 17, 2024 02:54
wavfile.py (enhanced)
# wavfile.py (Enhanced)
# Date: 20190213_2328 Joseph Ernest
#
# URL: https://gist.github.com/josephernest/3f22c5ed5dabf1815f16efa8fa53d476
# Source: scipy/io/wavfile.py
#
# Added:
# * read: also returns bitrate, cue markers + cue marker labels (sorted), loops, pitch
# See https://web.archive.org/web/20141226210234/http://www.sonicspot.com/guide/wavefiles.html#labl
# * read: 24 bit & 32 bit IEEE files support (inspired from wavio_weckesser.py from Warren Weckesser)
@patmandenver
patmandenver / setenv.sh
Created August 16, 2015 15:30
Tomcat8 setenv.sh
#
# Cutom Environment Variables for Tomcat
#
############################################
export JAVA_HOME=/usr/lib/jvm/java-7-oracle/jre
export PATH=${JAVA_HOME}/bin:${PATH}
############################################
#
# JAVA_OPTS
@seansummers
seansummers / cph.py
Last active April 17, 2020 17:08
Jython classPathHacker to load JDBC
def loadJar(jarFile):
'''load a jar at runtime using the system Classloader (needed for JDBC)
adapted from http://forum.java.sun.com/thread.jspa?threadID=300557
Author: Steve (SG) Langer Jan 2007 translated the above Java to Jython
Reference: https://wiki.python.org/jython/JythonMonthly/Articles/January2007/3
Author: seansummers@gmail.com simplified and updated for jython-2.5.3b3+
>>> loadJar('jtds-1.3.1.jar')
>>> from java import lang, sql
anonymous
anonymous / db2loadmessages.log
Created October 8, 2014 18:30
=================================================================
Messages start for DBO.CDINVDESIRABILITY
=================================================================
SQL3501W The table space(s) in which the table resides will not be placed in
backup pending state since forward recovery is disabled for the database.
SQL3039W The memory available to LOAD for DATA BUFFER prohibits full LOAD
parallelism. Load parallelism of "3" will be used
SQL2036N The path for the file, named pipe, or device
"/home/db2inst2/import/migr/dump/dbo_cdinvdesirability.txt" is not valid.
SQL2036N The path for the file, named pipe, or device
@mislav
mislav / arch.md
Last active January 11, 2022 11:33
How to create a base Vagrant box using VirtualBox

Create the partition:

sgdisk --zap-all /dev/sda
cgdisk /dev/sda
mkfs.ext4 /dev/sda1
mount /dev/sda1 /mnt

Edit the mirror list to bring the preferred mirror to the top:

@mustmodify
mustmodify / gist:40611a252f8bfbf9ab47
Last active January 26, 2018 21:08
ruby + nginx + puma
brand new slice as root:
One of these...
echo "America/New_York" > /etc/timezone
sudo dpkg-reconfigure --frontend noninteractive tzdata
or
sudo timedatectl set-timezone America/New_York