And here's a little write-up on how I approached the problem: https://nolancaudill.com/2011/01/01/how-to-build-a-quine/