fix behavior of credentials file parsing so that it overrides environment variables