function reflexive(x) {
return x != x;
}
reflexive(NaN)
function transitive(x,y,z) {
return x && x == y && y == z && x != z;
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
function j(u, c) { | |
var h = document.getElementsByTagName('head')[0], s = document.createElement('script'); | |
s.async = true; s.src = u; | |
s.onload = s.onreadystatechange = function () { | |
if (!s.readyState || /loaded|complete/.test(s.readyState)) { | |
s.onload = s.onreadystatechange = null; if (h && s.parentNode) { h.removeChild(s) } s = undefined; | |
if (c) { c() } | |
} | |
}; | |
h.insertBefore(s, h.firstChild); |
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
#!/bin/bash | |
# A script to set up a new mac. Uses bash, homebrew, etc. | |
# Focused for ruby/rails development. Includes many utilities and apps: | |
# - homebrew, rvm, node | |
# - quicklook plugins, terminal fonts | |
# - browsers: chrome, firefox | |
# - dev: iterm2, sublime text, postgres, chrome devtools, etc. | |
# - team: slack, dropbox, google drive, skype, etc |
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
## Generate a key | |
# openssl rand -base64 741 > mongodb-keyfile | |
## Create k8s secrets | |
# kubectl create secret generic mongo-key --from-file=mongodb-keyfile | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: mongo | |
labels: |
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
# Install Arch Linux with full encrypted btrfs subvolume inside luks | |
# Hardware: BIOS system, Intel GPU, Nvidia Optimus, Toshiba SSD, Wifi | |
# Please adjust for your needs. | |
# filename: install-arch-linux-on-btrfs-subvolume-inside-luks.txt | |
# The official guide: https://wiki.archlinux.org/index.php/Installation_Guide | |
# Download the archiso image from https://www.archlinux.org/download/ | |
# Copy to a usb-drive | |
dd bs=4M if=archlinux.iso of=/dev/sdx status=progress oflag=sync # on linux |
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 tkinter import * | |
from tkinter.colorchooser import askcolor | |
class Paint(object): | |
DEFAULT_PEN_SIZE = 5.0 | |
DEFAULT_COLOR = 'black' | |
def __init__(self): |
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
ruby '2.7.1' | |
gem 'rails', github: 'rails/rails' | |
gem 'tzinfo-data', '>= 1.2016.7' # Don't rely on OSX/Linux timezone data | |
# Action Text | |
gem 'actiontext', github: 'basecamp/actiontext', ref: 'okra' | |
gem 'okra', github: 'basecamp/okra' | |
# Drivers |
Syncing an Ethereum node is largely reliant on IOPS, I/O Per Second. Budget SSDs will struggle to an extent, and some won't be able to sync at all.
This document aims to snapshot some known good and known bad models.
For size, 4TB or 2TB come recommended as of mid 2024. A 2TB drive should last an Ethereum full node until late 2025 or thereabouts, with crystal ball uncertainty.
High-level, QLC and DRAMless are far slower than "mainstream" SSDs. QLC has lower endurance as well. Any savings will be gone when the drive fails early and needs to be replaced.
OlderNewer