Pull in export env dir logic