Optional cd zip

I don't like much the global vars approach, but don't have any better solutions yet.