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

Add social media cards #21

Closed
simonw opened this issue Sep 1, 2020 · 6 comments
Closed

Add social media cards #21

simonw opened this issue Sep 1, 2020 · 6 comments
Labels
enhancement New feature or request

Comments

@simonw
Copy link
Owner

simonw commented Sep 1, 2020

So sharing on twitter is nicer.

@simonw simonw added the enhancement New feature or request label Sep 1, 2020
@simonw
Copy link
Owner Author

simonw commented Sep 1, 2020

I'd really love to have screenshots of the posts as the social media card images. I wonder what the best way to achieve that would be?

@simonw
Copy link
Owner Author

simonw commented Sep 1, 2020

Built https://github.com/simonw/puppeteer-screenshot for screenshots. It takes a secret key, so the URL is something like:

https://puppeteer-screenshot.simonw.vercel.app/til.simonwillison.net/til/til/pytest_subprocess-server.md?key=...

I'm going to store the images in the database and use https://github.com/simonw/datasette-media to serve them.

simonw added a commit that referenced this issue Sep 1, 2020
@simonw
Copy link
Owner Author

simonw commented Sep 1, 2020

Added two new secrets to this repo:

Secrets

@simonw
Copy link
Owner Author

simonw commented Sep 1, 2020

Shipped and tweeted: https://twitter.com/simonw/status/1300868423774212096

It would be better if the aspect ratio was 2x1 though.

_2__Simon_Willison_on_Twitter___Added_social_media_preview_cards_to_my_TILs__https___t_co_H4Hg39EG9g____Twitter

simonw added a commit that referenced this issue Sep 1, 2020
Now also rebuilds DB from scratch if REBUILD in commit message.
@simonw
Copy link
Owner Author

simonw commented Sep 1, 2020

That GitHub Actions run (attempting to rebuild everything) took too long so I'm rebuilding and deploying once on my laptop.

@simonw
Copy link
Owner Author

simonw commented Sep 1, 2020

@simonw simonw closed this as completed Sep 1, 2020
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

No branches or pull requests

1 participant