Allow for specification of environment variables when bundle-ing

New pull request for work done previously in #21.