-
Notifications
You must be signed in to change notification settings - Fork 10
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
Consider using the Git Data API to support larger files #3
Comments
How do we get the value of The current action uses getContent(), which accepts the file path. |
I had to go a little digging to explore that question! I've identified at least 2 viable ways. Given that both of these approaches result in extra API calls, it might also be worthwhile to keep the current approach as the primary one, and only utilize this secondary approach if the request fails with a Combining the Repository Contents and Git Data APIs
Using only the Git Data API
|
Here's an updated and easier option! 🎉 TL;DR: Keep doing things as you are today, but just set this custom media type on the file retrieval request headers:
|
Created PR: #9 |
@sun + @Bhacaz, I have opened a PR to utilize the raw endpoint that @JamesMGreene mentioned: #23 Any interest in merging this into the action? If not, I will promote this to my own public action. Thanks! |
During a recent workflow run, I attempted to use the
checkout-files
Action to checkout a fairly largepackage-lock.json
file (npm lockfile) weighing in at about 2 MB. I received this unhandled promise rejection:You should consider using the Git Data API to support downloading larger files. 📦
The text was updated successfully, but these errors were encountered: