Skip to content

Instantly share code, notes, and snippets.

View jacobpatterson1549's full-sized avatar
🏢
Office work!

Jacob Patterson jacobpatterson1549

🏢
Office work!
View GitHub Profile
@jacobpatterson1549
jacobpatterson1549 / us_flag.svg
Created August 4, 2021 19:48
US Flag - 2020 (1!) Olympics
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jacobpatterson1549
jacobpatterson1549 / index.css
Created March 26, 2021 16:29
go-css-template-example
div.fireColor {
color: {{ .Colors.Fire }};
}
div.waterColor {
color: {{ .Colors.Water }};
}
@jacobpatterson1549
jacobpatterson1549 / query.go
Created March 4, 2021 00:31
sql.QueryRowContext with context timeout
// Package main runs a test to query a database backed by a mock driver.
// The test normally passes, but often fails when run with a large count and the go race detector:
// go run -race query.go --test.count=100
package main
import (
"context"
"database/sql"
"database/sql/driver"
"testing"