FantasticFiasco / action-update-license-year

GitHub Action that in a pull request updates the copyright year(s) in your license file.
Apache License 2.0
58 stars 2 forks source link

docs(readme): add scenario for triggering CI checks #272

Closed Swizbiz closed 2 years ago

Swizbiz commented 2 years ago

I configured it with using secrets.GITHUB_TOKEN. It ended normally, and made PR, but I faced trouble: my CI checks didn't start.

I found in GitHub Doc, that when workflow used secrets.GITHUB_TOKEN, it didn't trigger another workflows, such as CI: When you use the repository's GITHUB_TOKEN to perform tasks, events triggered by the GITHUB_TOKEN will not create a new workflow run. This prevents you from accidentally creating recursive workflow runs.

I also found: If you do want to trigger a workflow from within a workflow run, you can use a personal access token instead of GITHUB_TOKEN to trigger events that require a token. You'll need to create a personal access token and store it as a secret. So with this recommendation, you should create a personal access token . As a good security practice, you should always make sure that actions only have the minimum access they require by limiting the permissions granted to the token. And after that сreate a secret out of this token.

coveralls commented 2 years ago

Coverage Status

Coverage remained the same at 83.657% when pulling b6e7f50bca96aee9e2d69b35ff441cce7a8266ef on Swizbiz:master into eabe23266a6b3b1001b9e4d3b0d820cf954d239d on FantasticFiasco:master.

FantasticFiasco commented 2 years ago

Thanks! This will definitely help developer that will wan't to trigger other GitHub Actions workflows based on opened pull requests.