View rfc1234.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Hypertext Brad Protocol -- HBP/1.1 | |
Status of this Memo | |
This document specifies an Internet standards track protocol for the | |
Brad, and requests discussion and suggestions for | |
improvements. Please refer to the current edition of the "Internet | |
Official Brad Standards" (BSTD 1) for the standardization state | |
and status of this protocol. Distribution of this memo is unlimited. |
View Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM scratch | |
COPY demo / | |
CMD ["/demo"] |
View vercel.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"rewrites": [ | |
{"source": "/", "destination": "/api/index"}, | |
{"source": "/:splat*", "destination": "/api"} | |
] | |
} |
View resume_example.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package resume_test | |
import ( | |
"context" | |
"log" | |
) | |
func ExampleBackup() { | |
backup := func(ctx context.Context, object string) error { | |
job, err := resume.Call(ctx, "start", backupStart, object) |
View golangci-lint
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# github.com/golangci/golangci-lint/pkg/golinters | |
../../pkg/mod/github.com/golangci/golangci-lint@v1.27.0/pkg/golinters/gomodguard.go:47:36: unknown field 'k' in struct literal of type gomodguard.BlockedModule | |
../../pkg/mod/github.com/golangci/golangci-lint@v1.27.0/pkg/golinters/gomodguard.go:51:43: cannot use m (type gomodguard.BlockedModule) as type map[string]gomodguard.BlockedModule in append |
View nomoresticky.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package question | |
func whatsTheEquivalentOfThisWithHandleCheckQuestionMark(w io.Writer) (rN int, err error) { | |
w = LimitedWriter{w, 23} | |
n, err := io.WriteString(w, "some data 1") // 11 bytes written | |
rN += n | |
if err != nil { | |
return err | |
} |
View bench.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
function ready() { | |
function benchmark(n, f) { | |
var sum = 0.0; | |
var total = n; | |
while (n--) { | |
var u = 'https://google.com?q=1' + Math.random().toString(36).substring(7); | |
var s = performance.now(); | |
f(u); | |
var e = performance.now(); |
View bench.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
var i = 100000 | |
var r = [] | |
var a = document.createElement('a') | |
while (i--) { | |
var s = performance.now() | |
a.href = 'https://www.google.com?q=asdf' | |
var h = a.hostname | |
var e = performance.now() | |
r.unshift(e - s) |
View gist:9844247
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Coreo (pronouced: core-e-o) | |
Coreai | |
Coreholes | |
?? |
View http.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
func main() { | |
// ... setup ... | |
l, err := net.Listen("tcp", *laddr) | |
if err != nil { | |
log.Fatal(err) | |
} |
NewerOlder