Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
# Don't forget to `unset HISTFILE` before using this script ;¬)
#
# Check your password against Troy Hunt's massive password database.
# https://www.troyhunt.com/ive-just-launched-pwned-passwords-version-2/
full_hash="$(node -e "
const crypto = require('crypto');
const shasum = crypto.createHash('sha1');
shasum.update('${@}');
@alxndrsn
alxndrsn / couchdb_changes.md
Created February 20, 2017 05:51 — forked from nolanlawson/couchdb_changes.md
Anatomy of the CouchDB changes feed

Anatomy of the CouchDB changes feed

I just spent a lot of time finally understanding CouchDB's changes feed, so I thought I'd do a short writeup here.

The mystery

Let's imagine the following changes to the database. There are two documents, A and B:

_id seq rev winner?