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

Improved action workflow #1241

Merged
merged 3 commits into from
Nov 24, 2024
Merged

Improved action workflow #1241

merged 3 commits into from
Nov 24, 2024

Conversation

melroy89
Copy link
Member

@melroy89 melroy89 commented Nov 23, 2024

  • Let's try to use the built-in hashFiles function, and clean-up the yaml file

@melroy89 melroy89 added the enhancement New feature or request label Nov 23, 2024
@melroy89
Copy link
Member Author

melroy89 commented Nov 23, 2024

Interesting right? We do have a cache (cache hit).. And it does restore the cache..

But still unable to find the vendor binary from the directory? huh? Sure we can always trigger composer install, but shouldn't the cache restore not just contain these files.

I see, there is a special composer cache directory, which is not the same as the vendor directory. That is why.

image

Copy link
Member

@BentiGorlich BentiGorlich left a comment

Choose a reason for hiding this comment

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

I am just gonna trust you on this, as I don't know much about the github actions :)

@melroy89
Copy link
Member Author

melroy89 commented Nov 24, 2024

I am just gonna trust you on this, as I don't know much about the github actions :)

So instead of calculating the md5sum yourself. We use the built-in hashFiles function to hash the file. Which is used as a unique key index for caching. If the lock files didn't change, the same hash/key will be lookup. And therefore we have match (cache hit).

@melroy89 melroy89 enabled auto-merge (squash) November 24, 2024 12:25
@melroy89 melroy89 merged commit acf1f81 into main Nov 24, 2024
7 checks passed
@melroy89 melroy89 deleted the action_workflow_improvements branch November 24, 2024 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants