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
Adding action to auto-update releases data on deployment #108
Conversation
Co-Authored-By: jonrohan <rohan@github.com>
Dumb question: how do we test this locally? |
the script should work locally without any setup. verify it updated releases.json file |
Okay, cool. Could we add a run-script for it in {
"scripts": {
"update-releases": "./.github/actions/releases/entrypoint.sh"
}
} |
Okay now that I see how this works, I'm wondering: should we just do this in a |
I had it there at first but wasn't able to get it to work because of requirements 9c5de71 the build script failed, then the deploy script failed |
Which requirements? The slim image doesn't have |
|
Okay, lemme see if I can fix that up. There's a (basically) drop-in replacement called fx that we can install via npm. |
The deploy script was failing I think because it couldn't see the |
Ah, gotcha. So maybe we build the file in our actions and then make sure it's listed in |
@shawnbot are there any changes you'd still like to see on this or is this good to ship? |
@emplums Yeah, we've some conflicts to resolve first. I'm also still interested in knowing whether we can "just" move this to a |
Okay so I'm going to try to resolve the conflicts on this, and rebase if that doesn't work. If for some reason this PR doesn't jive with some more drastic changes scheduled in #152, then we may need to rethink the approach, e.g. getting releases with something like gatsby-source-github or gatsby-source-npm to render a static list at build time then (hopefully) have it hydrated with more timely data at runtime? /cc @colebemis for ideas ⚡️ |
Addresses part of #102, It will still need to be manual for any news events.
I've created an action that runs the get-releases-data script before deploying to now. This makes the .json file ready when deployed.
Deployed here https://primer-style-auto-release-updates.now.sh/news the releases exist even though the data file was emptied in this PR.
cc @shawnbot @emplums @broccolini