Skip to content

Instantly share code, notes, and snippets.

🎯
Focusing

Garrett Johnson gjohnson

🎯
Focusing
Block or report user

Report or block gjohnson

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View main.go
package main
import (
_ "context"
"flag"
"fmt"
"github.com/go-kit/kit/log"
"net/http"
"net/http/pprof"
"os"
View build.sh
docker run --rm -it -v "${GOPATH}":/gopath -v "$(CURDIR)":/app -e "GOPATH=/gopath" -w /app golang:1.7 sh -c 'CGO_ENABLED=0 go build -a --installsuffix cgo --ldflags="-s" -o app'
View keybase.md

Keybase proof

I hereby claim:

  • I am gjohnson on github.
  • I am gjj (https://keybase.io/gjj) on keybase.
  • I have a public key whose fingerprint is 407C A136 5E34 F542 4EF5 2A92 89A7 7D5B 4490 D956

To claim this, I am signing this object:

@gjohnson
gjohnson / Vagrantfile
Last active Jan 20, 2016
My base vagrant file
View Vagrantfile
required_plugins = %w( vagrant-faster vagrant-cachier vagrant-vbguest )
required_plugins.each do |plugin|
system "vagrant plugin install #{plugin}" unless Vagrant.has_plugin? plugin
end
Vagrant.configure(2) do |config|
config.vm.box = "ubuntu/vivid64"
config.vm.box_check_update = true
config.vm.network "private_network", ip: "192.168.33.10"
config.vm.synced_folder ".", "/vagrant"
View keybase.md

Keybase proof

I hereby claim:

  • I am gjohnson on github.
  • I am gjohnson (https://keybase.io/gjohnson) on keybase.
  • I have a public key whose fingerprint is 7B71 56A7 FD80 758A 7C28 9C1E CB19 3CB7 D752 24B2

To claim this, I am signing this object:

View gist:379beb7f5732eefd91ff
Vagrant.configure(2) do |config|
config.vm.provider "virtualbox" do |vb|
vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
vb.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
vb.customize ["modifyvm", :id, "--nictype1", "virtio"]
end
end
View id.go
package lunk
import (
"crypto/aes"
"crypto/cipher"
"crypto/rand"
"encoding/json"
"fmt"
"io"
"strconv"
@gjohnson
gjohnson / thing.lang
Last active Aug 29, 2015
xslt thing thing
View thing.lang
event.properties.* {
key = "${lowercase(.)}"
type = "string"
max = 255
min = 1
}
View contributing.md

Contributing

We're huge fans of open-source, and absolutely we love getting good contributions to segmentio/integrations! These docs will tell you everything you need to know about how to add your own integration to the library with a pull request, so we can merge it in for everyone else to use.

Getting Setup

To start, you need a couple of tools that will help you integrate as fast as possible:

@gjohnson
gjohnson / main.go
Created Aug 26, 2014
Ghetto idea of optional callbacks
View main.go
package main
import "fmt"
import "reflect"
func main() {
fn1 := createCallback()
fn1()
fn2 := createCallback(func() {
You can’t perform that action at this time.