The error must be happening at https://github.com/travis-ci/dpl/blob/v1.10.13/lib/dpl/provider/npm.rb#L33. Judging by the error message, NPM_API_KEY=#{option(:api_key)}
has spaces and “to
” is the word after the first space.
-
Since an API key isn’t supposed to have any spaces, not to mention prepositions, @pojntfx, are you sure you have encrypted the right value, and with the right key? (You are using travis-ci.com so you need to pass
--pro
to cli commands as per the link below.) Try encrypting it again as per https://docs.travis-ci.com/user/environment-variables/#encrypting-environment-variables (for this particular case, you need to encrypt just the raw value, without “MY_SECRET_ENV=
”). -
In https://raw.githubusercontent.com/pojntfx/mather.js/master/.travis.yml, I see that the
secure:
values have newlines – while the syntax produced bytravis encrypt
never has them. If you are sure you’ve encrypted the right value, try removing the newlines.