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

ci: go mod auto-update runs on push to curr #4666

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/go-mod-auto-bump.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
name: Go Mod Auto Version Update
on:
push:
branches:
- ${{ github.ref }}
Copy link
Member

@pysel pysel Mar 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think with this syntax the workflow will run only when the push to github.ref is made. However, this variable is only accessible when the workflow is running, so, I suspect, that when GH Actions check if the condition for this workflow is met, it will see github.ref as a blank string, because as I said, this variable is only accessible when workflow is running. I will check if that is indeed like that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if I am right, I will check out other ways of how this can be done properly

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, this workflow will never run with these changes

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is that a problem?

This should be checked once a push is made to the current branch. A push triggers the workflow run where github.ref is accessible

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand now. ChatGPT was confusing me here:

image

paths:
- osmoutils/**
- osmomath/**
Expand Down