Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] Control which changes trigger github actions #3

Closed
php1ic opened this issue Jun 3, 2020 · 5 comments
Closed

[FEATURE] Control which changes trigger github actions #3

php1ic opened this issue Jun 3, 2020 · 5 comments
Assignees
Labels
acknowledged The issue is being worked on enhancement New feature or request good first issue Good for newcomers implemented Feature was implemented and available

Comments

@php1ic
Copy link

php1ic commented Jun 3, 2020

Is your feature request related to a problem? Please describe.
Typo fixes in one of the *.md files will rerun the entire CI pipeline. Depending on how long the pipeline takes to run, this may become an issue.

Describe the solution you'd like
Control what triggers the CI pipeline via config.

Describe alternatives you've considered
Github actions doesn't seem to support skipping via a keyword in the commit message, so not sure there is an alternative.

Provide usage examples
See documentation link above

Additional context
I would create a PR, but I don't know if you want to implement a whilelist or a blacklist.

@php1ic php1ic added the enhancement New feature or request label Jun 3, 2020
@filipdutescu
Copy link
Owner

@php1ic sensible request. Ideally, you would have a separate branch (dev branch) which would then be merged with the master after multiple commits, but I understand the concern.

Since one might also want to run .sh, .py etc. on each change, I think the best approach would be to have a blacklist implementation, exempting .md files, for example.

I can look more into GitHub actions triggers, to ensure commit messages could or could not be used to stop triggering CI. If you wish, due to me getting to it only later today, you could also make a PR, which I will review.

Thank you for your feedback!

@filipdutescu filipdutescu added the good first issue Good for newcomers label Jun 3, 2020
@filipdutescu filipdutescu self-assigned this Jun 3, 2020
@Zethson
Copy link

Zethson commented Jun 3, 2020

@php1ic sensible request. Ideally, you would have a separate branch (dev branch) which would then be merged with the master after multiple commits, but I understand the concern.

I agree. (This is also Cookietemples default behavior. When a new project from a template is created a development branch is also created).
However, I still think that @php1ic brings up a nice point. You may not care if your repository is public, since you get CI for free, but it does matter for private repos.

I would like to second the blacklisting.

@filipdutescu Note however that your blacklist will change anyways since you will then blacklist the docs folder and rst files soon. So you can play around with it and later we can very easily change that.

@filipdutescu
Copy link
Owner

However, I still think that @php1ic brings up a nice point. You may not care if your repository is public, since you get CI for free, but it does matter for private repos.

Yes, I am in favour of this addition, which would help those having private repos.

@filipdutescu Note however that your blacklist will change anyways since you will then blacklist the docs folder and rst files soon. So you can play around with it and later we can very easily change that.

Does not seem too hard to include more file types in the blacklist, afterall I do not need to specify the file name (from my current understanding). There might also be a way to hse commit messages, but, as @php1ic mentioned, it is not standardized in GH Actions atm. Do you have any knowledge of such capabilities?

@Zethson
Copy link

Zethson commented Jun 3, 2020 via email

@filipdutescu
Copy link
Owner

@php1ic , @Zethson manage to fix the CI skipping with actual CI skipping.

Added CI Skipping

In your commit message, add [skip ci] or [ci skip] in order to not run workflows for the particular commit.

I.e.:

git commit -m "my normal commit message [skip ci]"

@filipdutescu filipdutescu added acknowledged The issue is being worked on implemented Feature was implemented and available labels Jun 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
acknowledged The issue is being worked on enhancement New feature or request good first issue Good for newcomers implemented Feature was implemented and available
Projects
None yet
Development

No branches or pull requests

3 participants