Skip to content

Instantly share code, notes, and snippets.

Joseph Spurrier josephspurrier

Block or report user

Report or block josephspurrier

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
@magnetikonline
magnetikonline / README.md
Last active Oct 12, 2019
List all Git repository objects by size.
View README.md

List all Git repository objects by size

Summary

Bash script to:

  • Iterate all commits made within a Git repository.
  • List every object at each commit.
@nathan-osman
nathan-osman / win32.go
Last active Jun 6, 2019
Simple Windows GUI application written in Go
View win32.go
package main
import (
"log"
"syscall"
"unsafe"
)
var (
kernel32 = syscall.NewLazyDLL("kernel32.dll")
@bradleypeabody
bradleypeabody / gist:185b1d7ed6c0c2ab6cec
Last active Sep 6, 2019
golang, convert UTF-16 to UTF-8 string
View gist:185b1d7ed6c0c2ab6cec
package main
// http://play.golang.org/p/fVf7duRtdH
import "fmt"
import "unicode/utf16"
import "unicode/utf8"
import "bytes"
func main() {
@johan
johan / index.md
Last active May 13, 2019
osx + java 7 = painfully easy
View index.md

Step 1

Does your osx terminal speak java 7? Start Terminal.app and try: java -version:

> java -version
java version "1.7.0_51"
Java(TM) SE Runtime Environment (build 1.7.0_51-b13)
Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)
@barryvdh
barryvdh / _ide_helper.php
Last active Oct 15, 2019
Laravel IDE Helper for Netbeans / PhpStorm / Sublime Text 2 CodeIntel, generated using https://github.com/barryvdh/laravel-ide-helper
View _ide_helper.php
<?php
/**
* A helper file for Laravel 5, to provide autocomplete information to your IDE
* Generated for Laravel 5.5.13 on 2017-09-28.
*
* @author Barry vd. Heuvel <barryvdh@gmail.com>
* @see https://github.com/barryvdh/laravel-ide-helper
*/
namespace {
exit("This file should not be included, only analyzed by your IDE");
@andelf
andelf / sendMail.go
Last active May 28, 2019
golang send mail net/smtp SMTP
View sendMail.go
package main
import (
"log"
"net/mail"
"encoding/base64"
"net/smtp"
"fmt"
"strings"
@hellerbarde
hellerbarde / latency.markdown
Created May 31, 2012 — forked from jboner/latency.txt
Latency numbers every programmer should know
View latency.markdown

Latency numbers every programmer should know

L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns             
Compress 1K bytes with Zippy ............. 3,000 ns  =   3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns  =  20 µs
SSD random read ........................ 150,000 ns  = 150 µs
Read 1 MB sequentially from memory ..... 250,000 ns  = 250 µs
You can’t perform that action at this time.