joshjohanning / joshjohanning.github.io

josh-ops.com | a devops blog
https://josh-ops.com
MIT License
8 stars 0 forks source link

img_path in posts doesn't work properly #21

Closed ruzickap closed 1 year ago

ruzickap commented 1 year ago

Hello.

I saw in your posts statements like:

https://github.com/joshjohanning/joshjohanning.github.io/blob/a439e09c4a5750963fcacb6ce428aeb98f5832f0/_posts/2022-10-07-using-github-checks-api.md?plain=1#L9-L11

This seems not to be working properly, because then the generated page https://josh-ops.com/posts/using-github-checks-api/index.html contains wrong image location 'https://josh-ops.com/status-check.gif' which obviously doesn't exist:

curl https://josh-ops.com/posts/using-github-checks-api/index.html | grep 'https://josh-ops.com/status-check.gif'

Maybe it would be better to use:

https://github.com/cotes2020/jekyll-theme-chirpy/blob/48f14e39ac81bbfb3b9913ea3ee789d775b2d1ae/_posts/2019-08-08-text-and-typography.md?plain=1#L9-L10

^^^ That is working correctly with images...

Maybe the bug is somewhere else, but I just wanted to let you know...

joshjohanning commented 1 year ago

Ahh! Good find @ruzickap.

It looks like the <meta property="og:image" meta tag is used when sharing on social media (link).

It looks like it's a bug, because as it's stated here:

In addition, the [img_path](https://chirpy.cotes.page/posts/write-a-new-post/#image-path) can also be passed to the preview image, that is, when it has been set, the attribute path only needs the image file name.

Reported the 🐛 upstream! https://github.com/cotes2020/jekyll-theme-chirpy/issues/754 😄