spatie / mailcoach-support

Questions and support for Mailcoach
https://mailcoach.app
31 stars 2 forks source link

Github actions tests and auth.json #177

Closed ziming closed 4 years ago

ziming commented 4 years ago

Currently my github action tests are failing as auth.json isn't in my project git repository.

Just wondering if you guys know how to deal with this issue.

freekmurze commented 4 years ago

You can set the content of auth.json as an environment variable https://getcomposer.org/doc/03-cli.md#composer-auth

So you could but the auth.json content in a GitHub secret and use that in your action. Here's an example: https://github.com/spatie/freek.dev/blob/cbfce05037b35825afd5285e376ddb2513c0d826/.github/workflows/run-tests.yml#L45-L48