Skip to content

Instantly share code, notes, and snippets.

View livingstaccato's full-sized avatar

Tim livingstaccato

View GitHub Profile
#!/usr/bin/ruby
# Create display override file to force Mac OS X to use RGB mode for Display
# see http://embdev.net/topic/284710
require 'base64'
data=`ioreg -l -d0 -w 0 -r -c AppleDisplay`
edids=data.scan(/IODisplayEDID.*?<([a-z0-9]+)>/i).flatten
vendorids=data.scan(/DisplayVendorID.*?([0-9]+)/i).flatten
#!/bin/bash
# This script is meant to reconnect your Mac to a wireless network.
# It is a brute force script and is meant to ensure there is only
# a single network being used/reconnected to.
#
# The script must be located in `${HOME}/.wifi-reconnect`
#
# There must also be a file called `config` in that directory
# that sets 3 environment variables:

Keybase proof

I hereby claim:

  • I am livingstaccato on github.
  • I am livingstaccato (https://keybase.io/livingstaccato) on keybase.
  • I have a public key ASCesxTgJHcs6LbKKw0BpfVsKCbXS4KCzp2kwx4Op03xXgo

To claim this, I am signing this object:

@livingstaccato
livingstaccato / vidcheck.sh
Last active August 31, 2016 16:34
ffmpeg video checker
#!/bin/sh
printf "Checking '${1}'… "
ffmpeg -v error -i "${1}" -f null - 2>"${1}.error"
if [ ! -s "${1}.error" ]; then
rm "${1}.error"
echo "Okay!"
else
echo "Errors found!"
@livingstaccato
livingstaccato / Install-Fonts.ps1
Created April 26, 2015 08:52
Install fonts using PowerShell
$FONTS = 0x14
$objShell = New-Object -ComObject Shell.Application
$objFolder = $objShell.Namespace($FONTS)
Get-ChildItem *.ttf | %{ $objFolder.CopyHere($_.FullName) }
@livingstaccato
livingstaccato / Install-InputMono.bat
Created April 26, 2015 08:46
Install Input Mono fonts
REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "InputMono BoldIta (TrueType)" /t REG_SZ /d InputMono-BoldItalic.ttf /f
REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "InputMono ExLight (TrueType)" /t REG_SZ /d InputMono-ExtraLight.ttf /f
REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "InputMono ExLightIta (TrueType)" /t REG_SZ /d InputMono-ExtraLightItalic.ttf /f
REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "InputMono Italic (TrueType)" /t REG_SZ /d InputMono-Italic.ttf /f
REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "InputMono Light (TrueType)" /t REG_SZ /d InputMono-Light.ttf /f
REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "InputMono LightIta (TrueType)" /t REG_SZ /d InputMono-LightItalic.ttf /f
REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" /v "InputMono Medium (TrueType)" /t REG_SZ /d InputMono-Medium.ttf /f
REG ADD "HKLM\SOFTWARE\Microsoft\Windows NT
Font=InputMono
FontHeight=10
FontSmoothing=full
Locale=en_US
Charset=UTF-8
ScrollbackLines=32768
Term=xterm-256color
BoldAsFont=no
ForegroundColour=171,171,171
BackgroundColour=0,0,0