Wrote documentation and cleaned up some stuff in the filesystem code.