Skip to content

Instantly share code, notes, and snippets.

View tommeier's full-sized avatar

Tom Meier tommeier

View GitHub Profile
@tommeier
tommeier / code_check.rb
Created April 29, 2013 01:46
Check for timezone aware rails code (using Cane: https://github.com/square/cane)
require 'set'
require 'cane/file'
require 'cane/task_runner'
module CaneExt
# Creates violations for files that do not meet code requirements.
class CodeCheck < Struct.new(:opts)
include Cane::CLI
@tommeier
tommeier / Steps for IE8
Last active December 16, 2015 06:49
Setting up IE8 on the hypervisor via Mac OSX
* Download IE8 image http://www.microsoft.com/en-us/download/details.aspx?id=11575
* Extract locally
* use VMWare vCenter Convertor Standalone
* Choose to select from third party image
@tommeier
tommeier / .htaccess
Last active August 19, 2020 03:55
Qnap Serviio Update Scripts
# reload after change "/etc/init.d/Qthttpd.sh restart"
php_value magic_quotes_gpc off
AuthName "Serviio - Admin Restricted Access (Use NAS admin credentials)"
AuthType Basic
# AuthUserFile /mnt/HDA_ROOT/rootfs_2_3_6/root/.htpasswd
AuthUserFile /mnt/HDA_ROOT/.config/shadow
AuthGroupFile /dev/null
# require valid-user
@tommeier
tommeier / update_serviio.sh
Last active December 15, 2015 18:09
Quick script to update Serviio as mentioned : http://forum.qnap.com/viewtopic.php?f=252&t=45994&start=435
#Compiled all into one gist:
#https://gist.github.com/tommeier/5324815
@tommeier
tommeier / tommeier.pp
Last active October 18, 2019 18:07
Boxen puppet file to load my local box
class people::tommeier {
require ruby
include chrome
include firefox
include iterm2::dev
include sublime_text_2
include caffeine
@tommeier
tommeier / application.html.erb
Created March 10, 2013 21:54
Speed up specs by disabling both jQuery effects and CSS transformations
<% if Rails.env.test? %>
<%= content_for :head do %>
<style type="text/css">
.notransition * {
-webkit-transition: none !important;
-moz-transition: none !important;
-o-transition: none !important;
-ms-transition: none !important;
transition: none !important;
}
@tommeier
tommeier / Rakefile
Created September 20, 2012 05:25
Rake Timer
require 'rake_timer'
@tommeier
tommeier / avatar.perl
Created September 14, 2012 05:37
Run Gource over your git repo
#!/usr/bin/perl
#fetch Gravatars
use strict;
use warnings;
use LWP::Simple;
use Digest::MD5 qw(md5_hex);
my $size = 90;
@tommeier
tommeier / upgrade_postgres_9.0.4-9.1.4.sh
Created July 17, 2012 04:35 — forked from databyte/upgrade_postgres_9.0-9.1.sh
Upgrade PostgreSQL from 9.0.4 to 9.1.4
#!/bin/sh
#
# Upgrade PostgreSQL from 9.0.4 to 9.1.4 via HomeBrew on Mac OSX
#
# by David Sommers (tweaked by me)
#
brew update
brew update postgres
@tommeier
tommeier / image_save.sh
Created July 16, 2012 01:00
Bash script to download list of image urls to a location
while read p; do
echo "SAVING : $p"
filename=$(basename "$p")
extension="${filename##*.}"
filename="${filename%.*}"
echo " -- Filename : $filename"
curl -o "/file/save/location/$filename.$extension" "$p"
done < /soure/url/list/image_list.txt