Skip to content

Commit c7f78f6

Browse files
DavidLiedleclaude
andcommitted
Convert book to org-mode and add GitHub Pages deployment
- Convert all 14 markdown chapters to proper org-mode format (headings, bold/italic/code, fenced blocks, blockquotes, links) - README.md → README.org (repo landing page with link to Pages site) - README.md index content → index.org (org-publish entry point) - Add publish.el: Emacs org-publish config with sidebar nav, prev/next chapter navigation, and custom HTML preamble/postamble - Add book.css: book-quality typography using IBM Plex font family, fixed sidebar nav, syntax highlighting, responsive layout - Add setup.org: shared #+SETUPFILE for font loading and CSS - Add .github/workflows/deploy.yml: GitHub Actions workflow that installs Emacs, runs org-publish, and deploys to GitHub Pages - Add .gitignore: exclude public/ build output Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 063d19d commit c7f78f6

21 files changed

+2303
-1656
lines changed

.github/workflows/deploy.yml

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
name: Build and Deploy Book
2+
3+
on:
4+
push:
5+
branches: [main]
6+
workflow_dispatch:
7+
8+
# Allow only one concurrent deployment
9+
concurrency:
10+
group: pages
11+
cancel-in-progress: true
12+
13+
permissions:
14+
contents: read
15+
pages: write
16+
id-token: write
17+
18+
jobs:
19+
build:
20+
runs-on: ubuntu-latest
21+
steps:
22+
- name: Checkout repository
23+
uses: actions/checkout@v4
24+
25+
- name: Install Emacs and dependencies
26+
run: |
27+
sudo apt-get update -qq
28+
sudo apt-get install -y --no-install-recommends \
29+
emacs-nox \
30+
elpa-htmlize
31+
32+
- name: Install Emacs packages (org, htmlize)
33+
run: |
34+
emacs --batch --eval "
35+
(require 'package)
36+
(add-to-list 'package-archives
37+
'(\"melpa\" . \"https://melpa.org/packages/\") t)
38+
(add-to-list 'package-archives
39+
'(\"gnu\" . \"https://elpa.gnu.org/packages/\") t)
40+
(package-initialize)
41+
(package-refresh-contents)
42+
(unless (package-installed-p 'htmlize)
43+
(package-install 'htmlize))
44+
(unless (package-installed-p 'org)
45+
(package-install 'org))"
46+
47+
- name: Build HTML book
48+
run: |
49+
mkdir -p public
50+
emacs --batch \
51+
--eval "(setq package-user-dir (expand-file-name \"~/.emacs.d/elpa\"))" \
52+
--eval "(require 'package)" \
53+
--eval "(package-initialize)" \
54+
-l publish.el \
55+
--funcall org-publish-all
56+
57+
- name: Setup GitHub Pages
58+
uses: actions/configure-pages@v4
59+
60+
- name: Upload Pages artifact
61+
uses: actions/upload-pages-artifact@v3
62+
with:
63+
path: public/
64+
65+
deploy:
66+
needs: build
67+
runs-on: ubuntu-latest
68+
environment:
69+
name: github-pages
70+
url: ${{ steps.deployment.outputs.page_url }}
71+
steps:
72+
- name: Deploy to GitHub Pages
73+
id: deployment
74+
uses: actions/deploy-pages@v4

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
public/
2+
.org-timestamps/
3+
*.elc
Lines changed: 25 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,15 @@
1-
# Chapter 1: Introduction - Welcome to the Org-Mode Rabbit Hole
1+
#+TITLE: Chapter 1: Introduction - Welcome to the Org-Mode Rabbit Hole
2+
#+AUTHOR: The Org-Mode with Emacs Authors
3+
#+LANGUAGE: en
4+
#+OPTIONS: toc:t num:t ^:nil H:4 html-style:nil
5+
#+SETUPFILE: setup.org
26

3-
You've probably heard whispers about Org-Mode. Perhaps you've seen that friend who seems oddly satisfied with their text-based life management system, or you stumbled upon a blog post claiming someone manages their entire existence in a `.org` file. Maybe you thought, "That can't be real."
7+
8+
You've probably heard whispers about Org-Mode. Perhaps you've seen that friend who seems oddly satisfied with their text-based life management system, or you stumbled upon a blog post claiming someone manages their entire existence in a =.org= file. Maybe you thought, "That can't be real."
49

510
Oh, but it is. And you're about to fall down one of the most productive rabbit holes in the computing world.
611

7-
## What is Org-Mode?
12+
* What is Org-Mode?
813

914
Org-Mode is deceptively simple at first glance: it's a major mode for GNU Emacs that handles notes, TODO lists, and project planning using plain text files. But calling Org-Mode "just a note-taking system" is like calling the ocean "a bit damp."
1015

@@ -23,38 +28,38 @@ Created by Carsten Dominik in 2003 (and now maintained by a dedicated community)
2328

2429
The real magic? All of this happens in plain text files that will outlive whatever fancy proprietary tool is trending this year.
2530

26-
## Why Org-Mode?
31+
* Why Org-Mode?
2732

28-
### The Plain Text Advantage
33+
** The Plain Text Advantage
2934

3035
Your notes from 1995 written in WordPerfect? Good luck opening those without archeological-level effort. Your notes from 2005 in that now-defunct web service? Gone when the startup folded. But plain text? Plain text is forever.
3136

32-
Org-Mode embraces this permanence. Your `.org` files are readable with any text editor, searchable with grep, version-controllable with git, and will be accessible decades from now. This is information longevity at its finest.
37+
Org-Mode embraces this permanence. Your =.org= files are readable with any text editor, searchable with grep, version-controllable with git, and will be accessible decades from now. This is information longevity at its finest.
3338

34-
### The Power of Text-Based Workflow
39+
** The Power of Text-Based Workflow
3540

3641
Here's something magical: when your entire workflow lives in text, automation becomes trivial. Want to generate reports from your task lists? Parse them. Want to track patterns in your time logs? Analyze them. Want to build custom workflows? Script them.
3742

3843
Try doing that with your favorite GUI task manager.
3944

40-
### The Joy of Keyboard-Driven Efficiency
45+
** The Joy of Keyboard-Driven Efficiency
4146

4247
Once you internalize Org-Mode's keybindings (and yes, there will be a learning curve), you'll find yourself managing complex information structures at the speed of thought. No clicking through menus, no reaching for the mouse—just pure keyboard-driven productivity.
4348

44-
## Who Should Use Org-Mode?
49+
* Who Should Use Org-Mode?
4550

4651
Org-Mode attracts a particular type of person:
4752

48-
- **The Optimizer**: You enjoy tweaking your workflows until they purr like a well-tuned engine
49-
- **The Skeptic**: You've tried seventeen different productivity apps and they all disappointed you
50-
- **The Writer**: You value distraction-free writing with powerful organizational capabilities
51-
- **The Programmer**: You appreciate that your notes can contain executable code that actually runs
52-
- **The Long-Term Thinker**: You want your data in formats that will outlast commercial software
53-
- **The Control Enthusiast**: You want to own your tools, not rent them
53+
- *The Optimizer*: You enjoy tweaking your workflows until they purr like a well-tuned engine
54+
- *The Skeptic*: You've tried seventeen different productivity apps and they all disappointed you
55+
- *The Writer*: You value distraction-free writing with powerful organizational capabilities
56+
- *The Programmer*: You appreciate that your notes can contain executable code that actually runs
57+
- *The Long-Term Thinker*: You want your data in formats that will outlast commercial software
58+
- *The Control Enthusiast*: You want to own your tools, not rent them
5459

5560
If you nodded along to any of these, welcome home.
5661

57-
## What This Book Will Teach You
62+
* What This Book Will Teach You
5863

5964
We'll start gentle—basic document structure, simple TODO lists, links—and progressively unveil Org-Mode's deeper powers. By the end, you'll be:
6065

@@ -66,21 +71,21 @@ We'll start gentle—basic document structure, simple TODO lists, links—and pr
6671
- Creating capture templates that make note-taking frictionless
6772
- And perhaps most importantly: understanding the Org-Mode philosophy
6873

69-
## A Word of Warning
74+
* A Word of Warning
7075

7176
Org-Mode will spoil you. After you experience the power of plain-text organization with Emacs-level extensibility, other tools will feel constraining. You might find yourself trying to use Org keybindings in your web browser (they won't work, sadly). You may become insufferable at dinner parties, evangelizing about the virtues of plain text.
7277

7378
Consider yourself warned.
7479

75-
## The Philosophy: Your System, Your Rules
80+
* The Philosophy: Your System, Your Rules
7681

7782
Here's what separates Org-Mode from prescriptive productivity systems: it doesn't tell you how to work. GTD enthusiast? Org-Mode can do that. Prefer Kanban? That too. Want to invent your own hybrid system? Go wild.
7883

7984
Org-Mode provides powerful primitives—headings, timestamps, tags, properties, links—and lets you compose them into whatever structure matches your brain. It's LEGO blocks for information management.
8085

81-
## Ready?
86+
* Ready?
8287

83-
In the next chapter, we'll get Org-Mode running and write your first `.org` file. Don't worry—we'll start simple. The terrifyingly powerful features come later.
88+
In the next chapter, we'll get Org-Mode running and write your first =.org= file. Don't worry—we'll start simple. The terrifyingly powerful features come later.
8489

8590
Take a deep breath. Save your work in whatever tool you're currently using (for nostalgia purposes—you won't be going back).
8691

0 commit comments

Comments
 (0)