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

test: only run actions on master #156

Merged
merged 1 commit into from
Jan 12, 2024
Merged

test: only run actions on master #156

merged 1 commit into from
Jan 12, 2024

Conversation

nobkd
Copy link
Collaborator

@nobkd nobkd commented Jan 11, 2024

Only run tests on commits / PRs to branch master or on manual dispatch from actions tab.
This prevents unnecessary runs and therefore saves action time usage.

Also, people typically don't do commits to the default branch of a fork, which also prevents workflows from running in their forked repo.
And if they have to, they can still run the workflow manually.


Just adding the billable time as a note: https://docs.github.com/en/billing/managing-billing-for-github-actions/about-billing-for-github-actions#included-storage-and-minutes

GitHub Free for organizations: 2,000 minutes (per month)

Operating system Minute multiplier
Linux 1
Windows 2
macOS 10

I mean, this won't really ever get hit. If we think of 30 days in a month:
$\frac{2000}{30}=66.\overline{6}$ minutes per day... which is won't be reached realistically. We take about 5 seconds for a run with this workflow. Even if there are more workflows...

@nobkd nobkd changed the title test: only on master test: only run actions on master Jan 11, 2024
@fritx
Copy link
Collaborator

fritx commented Jan 11, 2024

This prevents unnecessary runs and therefore saves action time usage.
GitHub Free for organizations: 2,000 minutes (per month)

Oops.. My bad. I didn't know it has a quota.. I thought it was totally free.

And if they have to, they can still run the workflow manually.

Makes sense. But an automatically run and a "pass or fail" logo display on a commit or a PR is quite useful, especially when maintainers doing code-review and considering is it safe to merge.

@nobkd
Copy link
Collaborator Author

nobkd commented Jan 11, 2024

On a commit to master or a PR to master the test should be run. If new commits are added to the pr, the workflow should run again. (See nobkd#1)

Therefore I think, that's alright.

@nobkd nobkd mentioned this pull request Jan 11, 2024
@tipiirai tipiirai merged commit 42fb3d1 into nuejs:master Jan 12, 2024
1 check passed
@nobkd nobkd deleted the not-master branch January 12, 2024 11:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants