commit c7551da77407a7f589a7fa657f79337f768010f7 parent 8525d00965630c8c886812d06dc852928fa88fc5 Author: MichaĆ M. Sapka <michal@sapka.me> Date: Thu, 2 Feb 2023 14:52:27 +0100 chore: do not embed yt Diffstat:
11 files changed, 14 insertions(+), 8 deletions(-)
diff --git a/content/2023/anathema-lost-control.md b/content/2023/anathema-lost-control.md @@ -14,4 +14,4 @@ Anathema is one two most influential bands of my childhood. It singlehandedly to As a teen, I spent countless hours on trains with a portable audio player armed with Alternative 4. I still consider it their greatest album, and it is still one of my favorites. -{{<youtube "uoDhH5QEfX0" >}} +{{<youtube "uoDhH5QEfX0" "Anathema - Lost Control" >}} diff --git a/content/2023/cradle-of-filth-her-ghost-in-the-fog.md b/content/2023/cradle-of-filth-her-ghost-in-the-fog.md @@ -24,6 +24,6 @@ I am not a metalhead, but we all love Cradle of Filth. It turns out that "we all" incorporated Ed Sheeran, who is [recording](https://blabbermouth.net/news/it-looks-like-cradle-of-filths-collaboration-with-ed-sheeran-is-finally-taking-shape) an album with COF! -{{<youtube "qRNfeMaUBbo" >}} +{{<youtube "qRNfeMaUBbo" "Cradle of Filth - Her Ghost in the Fog">}} diff --git a/content/2023/perfection-from-the-90s.md b/content/2023/perfection-from-the-90s.md @@ -11,7 +11,7 @@ Yes, the audio industry still does crazy design. Just look at Marantz! Dual, how > Wow. surprised to see this pop up. I designed this interface back in 1994 while at frogdesign. It's a handmade interface, written in machine code, running on a moto 6508 with 128kb ram- totally custom hardware and software build. Everything is custom drawn, even the fonts, as 4 bit art. And it supports a bunch of different languages. I -> (Mark Rolston commenting on the video) +> (Mark Rolston commenting on the video) -{{<youtube "ckiZf9X8GrY" >}} +{{<youtube "ckiZf9X8GrY" "Scifi Hifi" >}} diff --git a/extract_covers b/extract_covers @@ -1,7 +1,7 @@ #!/bin/bash echo "Extracting used YT ids..." -for id in `grep -r "<youtube" content/. | grep -o "\".*\"" | tr -d '"' ` +for id in `grep -r "<youtube" content/. | grep -o "\".*\"" | tr -d '"' | cut -d " " -f1 ` do echo "Processing $id"... diff --git a/layouts/shortcodes/youtube.html b/layouts/shortcodes/youtube.html @@ -1,5 +1,11 @@ -{{ $id := .Get 0 }} +{{- $id := .Get 0 }} +{{- $title := .Get 1 }} +{{- $path := printf "ytcovers/%s.jpg" $id}} +{{- $image := resources.Get $path }} +{{- $image = $image.Resize "x300" }} + <center> -<iframe id="ytplayer" type="text/html" width="500" height="280" - src="https://www.youtube.com/embed/{{ $id }}?autoplay=1&origin=https://michal.sapka.me" frameborder="0"></iframe> +<a href="https://www.youtube.com/watch?v={{$id}}" target="_blank"> + <img src="{{$image.Permalink}}" alt="{{$title}} on Youtube"/> +</a> </center> diff --git a/resources/_gen/images/ckiZf9X8GrY_hud2edf69d51c2b86d0ad45a8f420f7f04_24143_0x200_resize_q75_box.jpg b/resources/_gen/images/ckiZf9X8GrY_hud2edf69d51c2b86d0ad45a8f420f7f04_24143_0x200_resize_q75_box.jpg Binary files differ. diff --git a/resources/_gen/images/ckiZf9X8GrY_hud2edf69d51c2b86d0ad45a8f420f7f04_24143_0x300_resize_q75_box.jpg b/resources/_gen/images/ckiZf9X8GrY_hud2edf69d51c2b86d0ad45a8f420f7f04_24143_0x300_resize_q75_box.jpg Binary files differ. diff --git a/resources/_gen/images/qRNfeMaUBbo_hu7ec6ec90bbd0a4e209bf4e1c1864e6b7_11708_0x200_resize_q75_box.jpg b/resources/_gen/images/qRNfeMaUBbo_hu7ec6ec90bbd0a4e209bf4e1c1864e6b7_11708_0x200_resize_q75_box.jpg Binary files differ. diff --git a/resources/_gen/images/qRNfeMaUBbo_hu7ec6ec90bbd0a4e209bf4e1c1864e6b7_11708_0x300_resize_q75_box.jpg b/resources/_gen/images/qRNfeMaUBbo_hu7ec6ec90bbd0a4e209bf4e1c1864e6b7_11708_0x300_resize_q75_box.jpg Binary files differ. diff --git a/resources/_gen/images/uoDhH5QEfX0_hu760c38f7f200b95dbd8a0a6983e2ca1c_14442_0x200_resize_q75_box.jpg b/resources/_gen/images/uoDhH5QEfX0_hu760c38f7f200b95dbd8a0a6983e2ca1c_14442_0x200_resize_q75_box.jpg Binary files differ. diff --git a/resources/_gen/images/uoDhH5QEfX0_hu760c38f7f200b95dbd8a0a6983e2ca1c_14442_0x300_resize_q75_box.jpg b/resources/_gen/images/uoDhH5QEfX0_hu760c38f7f200b95dbd8a0a6983e2ca1c_14442_0x300_resize_q75_box.jpg Binary files differ.