homebrew-core
homebrew-core copied to clipboard
Update github actions to use composite action created before
- [x] Have you followed the guidelines for contributing?
- [x] Have you ensured that your commits follow the commit style guide?
- [x] Have you checked that there aren't other open pull requests for the same formula update/change?
- [ ] Have you built your formula locally with
brew install --build-from-source <formula>
, where<formula>
is the name of the formula you're submitting? - [ ] Is your test running fine
brew test <formula>
, where<formula>
is the name of the formula you're submitting? - [ ] Does your build pass
brew audit --strict <formula>
(after doingbrew install --build-from-source <formula>
)? If this is a new formula, does it passbrew audit --new <formula>
?
Here, I modified the github action to use the composite action I created on Homebrew/actions#289. Any feedback would be appreciated
I don't think the old version errored when it tried to do touch
-- we should probably try to replicate that behaviour.
I think you're right. We should look into that. @mohzulfikar, you can see the options that are set for bash here: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsshell
Wild guess: the action doesn't inherit permissions set in the calling workflow
That's weird actually. It passed on macos but not on linux. Any idea on how to debug this?
Probably user permissions -- the container runs as user linuxbrew
, but GitHub Actions expects something else. It may be that it's the GHA user running your action?
Hi there, sorry for stalling this PR. I've found the root cause for failing CI on Linux. It's because the working directory is not the default (set on the matrix). I want to test this change using my modified composite action first to see if it works.
But, it seems like the CI is not triggered, is there something I miss?
mohzulfikar/actions@main is not allowed to be used in Homebrew/homebrew-core. Actions in this workflow must be: within a repository owned by Homebrew, created by GitHub, or matching the following: Vampire/setup-wsl@, codecov/codecov-action@, google-github-actions/setup-gcloud@, peter-evans/, reitermarkus/, ruby/setup-ruby@, dessant/lock-threads@, google-github-actions/auth@, google-github-actions/get-gke-credentials@*.
I see, thanks for the confirmation. Seems like I need to modify the composite action on the Homebrew actions repository.
It seems like all checks have been successful. Any more feedback for this?
It looks like we're successful here. I'll go ahead and merge, and we can watch it in regular use.