Live data from Hacker News

Blog with Markdown and Git, and degrade gracefully through time

brandur.org

11–20 of 182 posts

Re: Blog with Markdown and Git, and degrade gracefully through time

#11

I am using Gatsby for my site https://www.bobbydreamer.com and saving the markdowns at git here https://github.com/bobbydreamer/bdv32 I haven't setup CI pipeline yet. It true whats said in the post, I used to save links thinking it won't disappear. But most the links, I had saved, it's no more.

I have a similar setup for my blog and I'm using Netlify for both CI and hosting (free). It's been great! GitHub Actions could probably work well for you if you already have decent hosting.

Re: Blog with Markdown and Git, and degrade gracefully through time

#12
I started my blog about python/django (https://simpleisbetterthancomplex.com) using Jekyll and hosting on Github Pages and it was pretty good to get started because back then I wasn't sure if I would keep it up or not.

After a year or so I migrated to a 5 USD droplet on Digital Ocean (back then GH Pages didn't offer https for custom domains) and integrated with Github webhooks to automate the deployment when pushing new markdown to the main branch.

Over the time it indeed started to degrade. The build time takes almost a minute, but after building the website is just a bunch of static html pages.

Nowadays it is annoying to write new posts because I like to write locally and refresh to browser to check if it's looking good or not. So I would say it degraded for me but for the reader it's still as fast as it was when there was just a couple of posts.

I thought about migrating the blog to something else, but because I used some custom markdown extensions for code highlight and other things, it would be painful to migrate all the blog posts. So I've been postponing it since 2019.

Re: Blog with Markdown and Git, and degrade gracefully through time

#13
post #8

I used to have my blog source on GitHub, but then it turned out I didn't want my half-finished works-in-progress public. To use a private repository would rather defeat the point; using a private repo and a public fork is inviting confusion. Now I just use a private repo on my own server, cloned to my dev machine. Does anyone have a usable solution for that problem?

I personally don't move anything into git until it's close to ready. WIP writing is kept on Bear (Markdown editor). But there are tons of other apps, including ones that sync to a cloud.

Re: Blog with Markdown and Git, and degrade gracefully through time

#14

I am using Gatsby for my site https://www.bobbydreamer.com and saving the markdowns at git here https://github.com/bobbydreamer/bdv32 I haven't setup CI pipeline yet. It true whats said in the post, I used to save links thinking it won't disappear. But most the links, I had saved, it's no more.

The only middle-way sort of solution I found a long time ago, even before joining the company, while looking where to host https://jdsalaro.com was to use GitLab, they being open-source and quite public about their, now our, values.

Nowadays I'm planning on writing again and have tried a setup that seems to be alright:

- migrate from Pelican to Hugo since the community is more vibrant, responsive and the themes much more mature and well maintained.

- Use a mature, well-maintained documentation-oriented template as base (I based https://jdsalaro.com off Pelican's bootstrap3)

- Create an Obsidian vault out of the posts/ directory to improve note-taking and editing capabilities.

- Host same as before on GitLab

- Deploy via CI/CD copying the posts/ directory to a public repository

- Probably mirroring to GitHub

I'll be able to report back once I've gotten the above fleshed-out :)

Re: Blog with Markdown and Git, and degrade gracefully through time

#15
post #8

I used to have my blog source on GitHub, but then it turned out I didn't want my half-finished works-in-progress public. To use a private repository would rather defeat the point; using a private repo and a public fork is inviting confusion. Now I just use a private repo on my own server, cloned to my dev machine. Does anyone have a usable solution for that problem?

I have a branch and remote called "publish", and a branch and remote called "draft". I suppose if I ever accidentally pushed the draft branch to the publish remote, I'd just delete the branch from the remote.

Re: Blog with Markdown and Git, and degrade gracefully through time

#16
I worked on a wiki that fell off the web; I've thought about recovering it from scrapes, and rewriting entries so that search wasn't needed, so that the Wayback Machine mirror worked better. Maybe using Kiwix tools to make a self-contained, downloadable backup, too.

Re: Blog with Markdown and Git, and degrade gracefully through time

#17

I wish people would stop using github as a swiss knife CDN (free hosting, hooks, history through git repo, etc) and build higher altitude solution that could leverage git/MD/whatever but with free/opensource/selfhosted/alternative tools (like gitea instead of github and minio instead of S3 for instance).

> build higher altitude solution that could leverage git/MD/whatever but with free/opensource/selfhosted/alternative tools

Not that I disagree with this, but that goes almost directly against "Mak[ing] that source public via GitHub or another favorite long-lived, erosion-resistant host. Git’s portable, so copy or move repositories as you go."

Any self-hosted service or solution is going to not be erosion-resistant by virtue of not being for-profit.

Re: Blog with Markdown and Git, and degrade gracefully through time

#18
Something that I feel is missing here is the problem with dead links. Even if the same content is still available on the very same blog, links might change when you decide to change your stack.

I might still be able to get around it, but it's still a pain.

Re: Blog with Markdown and Git, and degrade gracefully through time

#19
post #8

I used to have my blog source on GitHub, but then it turned out I didn't want my half-finished works-in-progress public. To use a private repository would rather defeat the point; using a private repo and a public fork is inviting confusion. Now I just use a private repo on my own server, cloned to my dev machine. Does anyone have a usable solution for that problem?

Stop caring about unfinished, public wip. In the end, nobody but you is really bothered by its imperfections.

I knew someone would say that. It's not about imperfections per se; more that I sometimes write stuff that I then reconsider and delete before it ever sees print. Admittedly nowadays I mostly self-censor that stuff before even starting to write it, but a few years ago I wrote a lot more stuff that, after reflection, I considered it would be unwise to go ahead and publish.

Re: Blog with Markdown and Git, and degrade gracefully through time

#20
post #9

I wish people would stop using github as a swiss knife CDN (free hosting, hooks, history through git repo, etc) and build higher altitude solution that could leverage git/MD/whatever but with free/opensource/selfhosted/alternative tools (like gitea instead of github and minio instead of S3 for instance).

why?

"free/opensource" -> !M$
Post reply on HN