use super::Block; #[derive(Clone, Copy, PartialEq, Eq, Debug)] pub enum PostKind { Letter, Poem, } impl PostKind { pub fn label(self) -> &'static str { match self { PostKind::Letter => "letter", PostKind::Poem => "poem", } } } #[derive(Clone, Copy, PartialEq, Eq, Debug)] pub enum Post { Letter20250824, Letter20250216, Awaken, } impl Post { pub const ALL: [Post; 3] = [Post::Letter20250824, Post::Letter20250216, Post::Awaken]; pub fn from_slug(slug: &str) -> Option { Self::ALL.into_iter().find(|post| post.slug() == slug) } pub fn slug(self) -> &'static str { match self { Post::Letter20250824 => "open-letter-2025-08-24", Post::Letter20250216 => "open-letter-2025-02-16", Post::Awaken => "awaken", } } pub fn title(self) -> &'static str { match self { Post::Letter20250824 | Post::Letter20250216 => "Open letter", Post::Awaken => "Awaken", } } pub fn kind(self) -> PostKind { match self { Post::Letter20250824 | Post::Letter20250216 => PostKind::Letter, Post::Awaken => PostKind::Poem, } } pub fn date(self) -> Option<&'static str> { match self { Post::Letter20250824 => Some("2025-08-24"), Post::Letter20250216 => Some("2025-02-16"), Post::Awaken => None, } } pub fn body(self) -> &'static [Block] { match self { Post::Letter20250824 => &[ Block::Paragraph("Hi,"), Block::Paragraph("It has been a couple of months since I quit GitHub. In this period I understood a couple of things:"), Block::Paragraph("Only (or mostly) big open-source projects are capable of reaching others and maintaining themselves without using GitHub."), Block::Paragraph("If you are a solo developer or a small team, you have already lost your chance to reach others when you self-host."), Block::Paragraph("Data security, backup and recovery processes are more serious things than they seemed."), Block::Paragraph("CI/CD processes are not free."), Block::Paragraph("Even non-technical people are familiar with GitHub, and it's an indicator for HR departments when applying for a job."), Block::Paragraph("I'm still in the same position as in my 16 February 2025 letter. GitHub is still closed source and owned by Microsoft. I want to own my own code but still need to reach the community, get better CI/CD and have reliable backup opportunities. So from now on,"), Block::Paragraph("I will mirror my repos to different platforms, including GitHub."), Block::Paragraph("Best wishes,"), Block::Paragraph("Ahmet Kaan Gümüş"), ], Post::Letter20250216 => &[ Block::Paragraph("Hi,"), Block::Paragraph("Since I'm an open-source developer and a person who relies on open source software, I realized there is a massive contradiction between my perspective and my life. It's GitHub, which is run by Microsoft. It took me a lot of time to understand what I'm doing after using it for many years and pushing thousands of commits for tens of projects."), Block::Paragraph("I don't want this situation to continue. From now on,"), Block::Paragraph("I have archived all of my repositories and plan to log in only for opening issues and pull requests for other projects."), Block::Paragraph("My new projects will not be hosted there."), Block::Paragraph("If an existing project needs an update, or I want to add new things, it will not be there."), Block::Paragraph("You can follow my projects and source codes from https://tahinli.com."), Block::Paragraph("Best wishes,"), Block::Paragraph("Ahmet Kaan Gümüş"), ], Post::Awaken => &[ Block::Lines(&[ "Does every word flies, if it's not written.", "A life goes by a word that is written.", "Word doesn't know what is written.", "Only feels why it's written.", ]), Block::Lines(&[ "Things come and go with a light.", "A cry is woken by the light.", "Does ever the light's gone for a blind.", "Maybe awaken is blinded by the light.", ]), Block::Lines(&[ "Time goes with a paper and blood.", "The blood will end by the paper and a heart.", "The paper came with the blood and a knife.", "Hearts will die with the time and the blood.", ]), Block::Lines(&[ "Sirens are here to wake.", "The awaken is ready to take a break.", "Screams goes where, when a silence comes to take.", "Take the gap to get a moment to wake.", ]), Block::Lines(&[ "The awaken can't feel a thing what is real.", "Does ever be a thing that is not surreal.", "Real isn't the moment to be there to deal.", "Deal is ever be a thing in real.", ]), Block::Lines(&[ "Blooded writes these down with a blind mind.", "A mind came by the light to get a heart of a knife.", "The knife cuts the light in a written time.", "The written is the siren for the awaken to die.", ]), ], } } }