This repository is a template of CI for Flutter project.
Big thanks to The Jared Wilcurt for the technique explained here.
- First you need to create a public gist in Github gist. Copy the id of the gist (you can find it in the URL just after your username).
- Create a secret called
GIST_ID_COVERAGE_BADGE
with the ID of the created gist as value. - Create a developer token with the
gist
scope. Copy the token. - Create a secret called
GIST_COVERAGE_BADGE_TOKEN
with the token just created at the previous step as value. - Do not forget to copy
scripts/ci_determine_coverage_percentage.sh
in your repository. - Add this badge to your README:
[![Coverage Badge](https://img.shields.io/endpoint?url=https://gist.githubusercontent.com/<YOUR_USERNAME>/<YOUR_GIST_ID>/raw/<REPOSITORY_NAME>_master_badge_coverage.json)]
- There you go! 😄
When you wish to regenerate the goldens files of your project, simply add [CI UPDATE GOLDENS]
to your commit message.
The CI will update all the goldens files during the testing
job then will push the new/updated files.
test
folder of the project. Otherwise, update Commit golden files
step under the testing
job.
- Create a developer token with the
repo
scope. Copy the token. - Create a secret called
PAT
with the token just created at the previous step. - Enjoy! 😄
- Split action by JungWinter
- Tag exists action by mukunku
- Flutter action by subosito
- LCOV reporter action by romeovs
- Dynamic badge action by schneegans
- Automatic releases action by marvinpinto
- Auto commit action by stefanzweifel