building-secure-contracts icon indicating copy to clipboard operation
building-secure-contracts copied to clipboard

Only run github action if related files are changed

Open montyly opened this issue 2 years ago • 3 comments

For example when we change markdown files that are not related to Echidna, we should not run all the echidna tests

montyly avatar Feb 15 '23 15:02 montyly

Perhaps @elopez has some idea on how to solve this, since it looks like a "generic CI issue".

gustavo-grieco avatar Feb 15 '23 16:02 gustavo-grieco

paths and paths-ignore can be used to implement this: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onpushpull_requestpull_request_targetpathspaths-ignore

elopez avatar Feb 15 '23 16:02 elopez

We could use something like https://github.com/dorny/paths-filter or https://github.com/MarceloPrado/has-changed-path to conditionally execute the action steps. E.g. if only Echidna exercise 4 is updated then there's no need to run all exercise tests in the Echidna action.

tuturu-tech avatar Mar 03 '23 15:03 tuturu-tech