Move credentials helper code into bin/credentials-helper