Skip to content

Instantly share code, notes, and snippets.

View joerodriguez's full-sized avatar

Joseph Rodriguez joerodriguez

  • Expel
  • Boulder, CO
View GitHub Profile
@joerodriguez
joerodriguez / gist:99d5fc6d03ec11591532abcb3871276a
Last active October 2, 2018 19:13
simplified indicators format
---
apiVersion: v0
product: healthwatch
version: v1.4
metadata:
deployment: <%= spec.deployment %>
indicators:
@joerodriguez
joerodriguez / delete_dupe_mp3.sh
Created November 9, 2015 00:04
Delete duplicate mp3s
find . -type f -name '* 2.mp3' | while read fpath; do orig=`echo $fpath | perl -pe 's/ 2\.mp3$/\.mp3/'` ; if test -e "$orig" ; then rm "$fpath"; echo "deleted $fpath"; fi; done > deleted.log
plugins {
id "com.moowork.gulp" version "0.9"
}
apply plugin: 'com.moowork.gulp'
node {
version = '0.10.22'
download = true
}
events = {
processed: 99,
open: 32,
click: 12,
spam: 1
}
subaccounts = [
"8a9dhf",
"3984hi",
@joerodriguez
joerodriguez / stress.go
Last active August 29, 2015 14:04
Stress test for traffic controller with many CLI connections
package main
import (
"flag"
"fmt"
"os"
"os/exec"
"os/signal"
"sync"
)
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<style>
.AlignLeft { text-align: left; }
.AlignCenter { text-align: center; }
.AlignRight { text-align: right; }
body { font-family: sans-serif; font-size: 11pt; }
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<style>
.AlignLeft { text-align: left; }
.AlignCenter { text-align: center; }
.AlignRight { text-align: right; }
body { font-family: sans-serif; font-size: 11pt; }
@joerodriguez
joerodriguez / gist:7652481
Created November 26, 2013 02:12
filebot movie renamer
// PERSONALIZED SETTINGS
def movieDir = '''/in/Movies'''
def movieFormat = '''/out/Movies/{n} ({y})/{n} ({y}){" CD$pi"}'''
// ignore chunk, part, par and hidden files
def incomplete(f) { f.name =~ /[.]incomplete|[.]chunk|[.]par$|[.]dat$/ }
// extract completed multi-volume rar files
[movieDir].getFolders{ !it.hasFile{ incomplete(it) } && it.hasFile{ it =~ /[.]rar$/ } }.each{ dir ->
// extract all archives found in this folder
@joerodriguez
joerodriguez / encode.sh
Last active December 28, 2015 20:38 — forked from botsmack/encode.sh
remix with ffmpeg if input is already avc
#!/bin/bash
# encode.sh
#
# Copyright (c) 2013 Don Melton
#
# This version published on June 7, 2013.
#
# Re-encode video files in a format suitable for playback on Apple TV, Roku 3,
# iOS, OS X, etc.
$('div.toc a').bind('click', function(event) {
go_to_top();
$.get($(this).attr("href"), $(this).serialize(), null, "script");
if ( history.pushState ){ // trying to use this clause to check pushState compability
event.preventDefault();
history.pushState(null, "", this.href); // pushes the URL to link bar
}
return false;