-
-
Notifications
You must be signed in to change notification settings - Fork 0
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
I think your archive job always uploads yesterday‘s screenshot #1
Comments
ahhh yeah I just made amends with it since it would eventually get everything haha. thank you for figuring out how to do it by avoiding checking out the repo entirely! gonna integrate this :) hope you enjoy your archive of website screenshots |
i had also wanted to make it so it just commits every new photo to the repo (folder per side, with date as the name) rather than to s3.. you inspired me with this issue to try to get that working again but alas still seems unsupported (simonw/shot-scraper#130). if this is interesting to you and you figure it out let me know haha |
I don't know enough python to be able to do this in a ”nice“ way. But I think you can do it with github actions relatively easily. You could re-use the code you already have in the action to generate the file name, rename the file after the screenshot is created, and then the step that commits and pushes to the repo will handle everything else. I tried this on my repo and it seems to work - yours would be a bit different because you have two screenshots - but I think you'd just need to add another |
oh yeah ur a genius LOL updated it to do that :) thanks for the help |
Nice! Glad that it's all working, and once again thanks for the idea - I'm just sad I didn't start this 5 years ago 😄 |
I like the idea of archiving your site everyday, and so I copied your action code. I realised that it actually upload yesterdays screenshot. (I only spotted this cos I had changed the page being screenshotted today).
The reason this happens is that actions are run on a specific commit, so even though the first job pushes an updated version of the repo, when the second job checks out the repo, it's still fetching the old commit.
I got around this by storing the screenshot as an artifact, you can see the change in this commit in case you want to make the same change here.
The text was updated successfully, but these errors were encountered: