Refactor branch name sanitize
Break out environment for latest into own method

Include environment as a instance variable
Merge pull request #2 from petecheslock/refactor

Refactor