Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

@rmulley
rmulley / Makefile-go
Last active August 29, 2015 14:12
Go Makefile
GO ?= go
export GOPATH := $(CURDIR)/_vendor:$(GOPATH)
all: build
build:
$(GO) fmt src/*
$(GO) vet src/*
$(GO) build -o ./bin/program_name src/main.go
@rmulley
rmulley / golang_emails.go
Last active December 11, 2016 03:17
Sends an email in Go with text/HTML and an attachment.
package main
import (
"bytes"
"encoding/base64"
"fmt"
"io/ioutil"
"log"
"net/smtp"
) //import
@rmulley
rmulley / mysql_stmt_close.pl
Last active December 22, 2015 20:19
Searches MySQL general log for unclosed prepared statements
use strict;
use warnings;
my %pids;
#open log file
open LOG, "<mysql-general.log";
#check file opened properly
if(!fileno(LOG)) {