博客与个人写作2018sadiqpk.org
用 Emacs org-mode 写博客
Blogging with Emacs org-mode
导读
这篇文章介绍如何用 Emacs org-mode 搭建并发布博客,评论区则集中讨论了各种静态站点生成与托管方案。对写作者而言,真正值得读的是其中反复出现的提醒:工具配置很容易变成拖延的借口,先把文章写出来、发出去,比把流程打磨完美更重要。
可以直接用的写作要点
- 01
先发出第一篇再优化工具链:折腾脚本和配置最容易消耗写作动力,很多人还没动笔就放弃了。
- 02
选一条最短的发布路径,比如直接用现成平台或让平台原生渲染源文件,省掉导出、转换等中间环节。
- 03
发布前在本地预览渲染效果,确认排版和代码示例显示正常,再同步到服务器,避免上线后返工。
- 04
主题和模板只做小幅修改就够用,把剩下的精力留给内容而不是无限重构站点。
HN 评论精选
工具折腾会吞噬写作动力,简单平台反而更容易真正开始写。
我曾尝试过这套做法,结果陷进了折腾小脚本、各种 hack 和反复试用的兔子洞,还没写出第一篇博客就失去了动力。下次想写博客,我就直接放到 wordpress.com 之类的平台上。
Scarblac查看英文原文
I once tried to do this as well, and got sucked into the rabbit hole of tinkering with little scripts and hacks and trying things out and never writing my first blog post before I lost motivation. Next time I feel like I want to write a blog I'll just put it on wordpress.com or so.
让托管平台直接渲染源文件,可以省掉导出环节,缩短从写作到发布的路。
我发现 GitHub 自带 org mode 渲染器,于是一直在写一篇直接托管在 GitHub 上、不需要导出成 HTML 的博客。渲染器有些问题,但代码示例显示还行。示例用的未完成文章在这里……哪天我还想看看能不能在 GitLab 上做类似的事,用带 Emacs 的 docker 镜像导出 HTML 生成静态页面应该不难。
mikekchar查看英文原文
I realised a while ago that Github had an org mode renderer. So I've been working on a blog post that's hosted directly on Github (without needing to export to HTML). The renderer has some problems, but it's been OK for my code examples. Completely unfinished blog post here for example purposes only: https://github.com/ygt-mikekchar/oojs/blob/master/oojs.org You can look at raw mode to see what the source code looks like. One of these days, I'm going to see if I can get something similar working on GitLab (which I've started using and admit to liking better at the moment). I think it should be easy, if a bit expensive (for them) because I should be able to set up a docker image with Emacs and export the HTML to generate a static page. P.S. Anyone interested in the content of my blog post -- I got stalled trying to reason about the purpose of "this/self", but I've unstuck myself and should be finishing it up soon.
git 驱动的工作流顺手,但只需小幅定制主题,不必大改。
我用 org-page 写博客,如果你习惯用 git,它的工作流很不错,和 GitHub Pages 集成得很好。这个项目看起来已经停止维护了(或者说是稳定了!?),但我一直在用,因为我小幅改过默认主题,做出来的站点很干净。也许以后我会改用原生 org-mode 生成静态网站,因为我最近总想给 Emacs 配置删依赖。
clircle查看英文原文
I use org-page (https://github.com/kelvinh/org-page) to write my blog. It has a pretty cool workflow if you are into git, and integrates well with github pages. The project seems to be dead (or stable!?), but I keep using it because I made some small tweaks to the default theme, which resulted in a clean looking website. Maybe I'll switch to vanilla org-mode for static website generation in the future since I seem to always be in the mood to remove dependencies from my emacs config these days.
本地构建预览、确认渲染后再同步上线,是稳妥的发布流程。
Nikola 有一个 orgmode 插件,对我的博客来说够用了。写完文章后,Nikola 会增量构建站点,我可以在本地查看确认渲染效果,最后用 rsync 把改动同步到 Web 服务器。
mc_查看英文原文
Nikola[0] has an orgmode plugin[1] that works fine for my blog. After I write something up, nikola builds the site (incremental build), I can view it locally to verify the rendering, and finally rsync the changes up to the web server. [0] https://getnikola.com/ [1] https://plugins.getnikola.com/v8/orgmode/
同类还值得读
我坚持每天写一条 TIL,已经写了一年
Show HN: I've been writing daily TILs for a year
这篇展示作者一年每天写 TIL(Today I Learned)并整理到 GitHub 仓库的做法。
博客与个人写作2016 · 819 分 · 150 评4 条写作要点编辑精选如何写出开发者愿意读的博客文章
How to write blog posts that developers read
这篇(正文与评论未提供,仅从标题判断)讨论面向开发者写技术博客的方法:怎样让忙碌的工程读者愿意点开、读下去并读到结尾。
博客与个人写作2025 · 603 分 · 154 评4 条写作要点编辑精选博客写作风格指南
A blogging style guide
这是程序员兼博主 Robert Heaton 的博客写作风格指南,用几十条简短规则讲如何让技术文章更清晰、更好读。
博客与个人写作2018 · 495 分 · 188 评4 条写作要点编辑精选十年职业博客写作,我学到了什么
Ten years of professional blogging – what I’ve learned
这是作者回顾十年专业博客写作经验的总结,评论补充了写作作为深度学习、聚焦主题、保护写作习惯和选择发布平台等实践。
博客与个人写作2017 · 362 分 · 126 评4 条写作要点编辑精选十年博客写作教给我的事
What I learned in ten years of blogging
这是一篇博客作者十年写作经验总结,核心观点是写作的价值在于持续积累而非单篇爆款。
博客与个人写作2018 · 356 分 · 162 评4 条写作要点编辑精选