Refactor to use a single defines block and share the logic
Add spec for ensuring it will fail on an unknown version
Fix up for lint
Fix dependency on folder extraction