Skip to content

Instantly share code, notes, and snippets.

@meowsbits
meowsbits / team-development-infrastructure-phase1.md
Last active Dec 4, 2018
Development team infrastructure, etc. / Phase 1
View team-development-infrastructure-phase1.md

Remote version control

  • Github org (/etclabs, /bestwisdom?)
    • Membership at reader/writer (admin+) level for all developers

CI pipelines

  • CircleCI account (possibly Pro) > Handles OSX and Linux tests and builds and integrates seamlessly w/ Github
@meowsbits
meowsbits / aligning-images.md
Created Mar 13, 2019 — forked from DavidWells/aligning-images.md
Guide to aligning images in github readme.md files
View aligning-images.md

Aligning images

left alignment

This is the code you need to align images to the left:

View lazy_evaluation.go
package main
import (
"time"
)
type LazyInt chan func() int
// Can't use pointer receiver: invalid operation: l <- (func literal) (send to non-chan type *LazyInt)
func (l LazyInt) Future(i int) {
View example.go
// Code generated by go-openrpc. DO NOT EDIT.
package main
import (
"bytes"
"encoding/json"
rpct "github.com/gregdhill/go-openrpc/rpc"
"io/ioutil"
"log"
"net/http"
@meowsbits
meowsbits / gh-clonepullrequests
Created Dec 2, 2019
Clone Github Pull Requests.
View gh-clonepullrequests
#!/usr/bin/env bash
help() {
if [[ ! -z "$1" ]]
then
echo "Error: $1"
trap 'exit 1' RETURN
fi
cat <<EOF
View gh-cloneissues
#!/usr/bin/env bash
help() {
if [[ ! -z "$1" ]]
then
echo "Error: $1"
trap 'exit 1' RETURN
fi
cat <<EOF
@meowsbits
meowsbits / LICENSE
Last active Dec 4, 2019
Github Discourse Archiver
View mordor-peers.txt
enode://c72df580434982156ff1c713bed3b70f146a4aca5221f2912398fcc3f7060ec5898a7b9a365f691fdc2e09b893574c84acbc501b9fb91512deee950df540949b@104.215.6.163:32303
enode://111bd28d5b2c1378d748383fd83ff59572967c317c3063a9f475a26ad3f1517642a164338fb5268d4e32ea1cc48e663bd627dec572f1d201c7198518e5a506b1@88.99.216.30:54568
enode://07fa944c83597d5e935a2abe6194ed40fc7239e86111c971a43537a33d0184d1cd1b3f1291b8dd3bcfaebfbb802de77c843465a00065b39120c338fdd877ca4a@35.238.126.60:53660
enode://17e7589e71013b05a48ef4edb33ac4a73ec0a7c45f8515729ec3e97d8d881a81c31a36a42933453440e5aa51c2c9e413f930c9684dbfbb878a54e80c30949cca@40.74.75.180:45706
enode://88867ca902de01ecbaa7faf6058316480e4566126cd4e63f4efd83d3a3b014316ca2056573efbad45ea097936ad139079b0298f599a255ca50e0a5a7558916fd@98.11.188.110:32994
enode://0c4dd99f9b230c6be3988fe9bc031097789749835e8ca447092de002cd90db737fb8cf66edf7269b043e3bc49fc8aa800c9e30b685c86d54b6fd8b7d59c577d6@13.71.140.242:30303
enode://f50f52b5fe18fd281748905bf5dad5439471f32cc02d99fecf960a983c1f4eba701ffca96afd
View forkid_gen_cases_test.go
func TestGenerateCases(t *testing.T) {
type testcase struct {
head uint64
want ID
}
tests := []struct {
name string
config ctypes.ChainConfigurator
genesis common.Hash
@meowsbits
meowsbits / sort-big-csv.sh
Created Dec 31, 2019
Script sorts a big (90GB+) CSV file
View sort-big-csv.sh
#!/usr/bin/env bash
# Sorts a big CSV file by breaking it into small pieces, sorting those, then merging (while sorting) those
# small pieces back into a big one.
# Largely (get it?) taken from https://stackoverflow.com/a/34092506/4401322
# Break big file into small chunk files.
# Set how many lines per chunk file you want.
split -l 1000000 "$1" chunk-