Refactored things to allow for easier setting of environment variables. Added links (but still buggy).