docs
Workflow| modified | Saturday 9 May 2026 |
|---|
This guide explains how XLog works and how to integrate it into your daily workflow.
XLog follows a desktop-first editing workflow that integrates with your existing text editor. Here’s what makes it unique:
┌─────────────────────────────────────────────────────────┐
│ Your Text Editor (Vim, VS Code, Emacs, etc) │
│ ↓ Edit & Save │
│ Markdown Files (Filesystem) │
│ ↓ XLog watches for changes │
│ XLog Server (Live Preview) │
│ ↓ Hot-reload │
│ Browser (Instant Preview) │
└─────────────────────────────────────────────────────────┘
Key Insight: XLog doesn’t replace your editor—it enhances it with live preview and knowledge-base features.
When you click the “Edit” button in your browser:
Important: There is NO in-browser editing. This is intentional—your editor is more powerful than any web-based solution.
XLog uses the -editor flag or $EDITOR environment variable to know which editor to open.
Default behavior:
1xlog # Uses $EDITOR if set, otherwise tries common editors
Specify editor explicitly:
1xlog -editor "code" # VS Code
2xlog -editor "vim" # Vim
3xlog -editor "emacs" # Emacs
4xlog -editor "subl -w" # Sublime Text (wait for close)
5xlog -editor "code --wait" # VS Code (wait for close)
Set permanently in shell:
1# Add to ~/.bashrc or ~/.zshrc
2export EDITOR="code --wait"
1# Option 1: Set globally
2export EDITOR="code --wait"
3
4# Option 2: Pass flag
5xlog -editor "code --wait"
Recommended VS Code extensions:
1# Already works if $EDITOR is set
2export EDITOR="vim"
3
4# Or use Neovim
5export EDITOR="nvim"
Recommended Vim plugins:
1# Use emacsclient for faster startup
2export EDITOR="emacsclient -n -a emacs"
3
4# This is XLog's default if no $EDITOR is set
Recommended Emacs packages:
1export EDITOR="subl -w" # -w waits for file close
Atom:
1export EDITOR="atom --wait"
Nano:
1export EDITOR="nano"
Custom GUI editor:
1# Replace with your editor's command
2export EDITOR="/path/to/editor"
1# Terminal 1: Start XLog
2cd ~/notes
3xlog
4
5# Terminal 2: Create new note
6echo "# Meeting Notes - 2026-05-07" > meetings/daily-standup.md
7
8# Browser: Navigate to http://localhost:3000/meetings/daily-standup
9# Click "Edit" → Editor opens → Add content → Save
10# Browser auto-refreshes with changes
1# Organize by topic with hashtags
2# In your editor, create: research/quantum-computing.md
3
4---
5# Quantum Computing Basics
6
7#physics #computing #research
8
9Quantum computers use qubits instead of bits...
10
11Related: [classical-computing](/classical-computing) [quantum-entanglement](/quantum-entanglement)
12---
13
14# XLog automatically:
15# - Creates backlinks from referenced pages
16# - Indexes hashtags for browsing
17# - Adds to search index
1# Project structure
2my-docs/
3 index.md # Homepage
4 getting-started.md
5 api/
6 authentication.md
7 endpoints.md
8 public/
9 logo.png
10 diagrams/
11
12# Develop with live preview
13xlog
14
15# Deploy as static site
16xlog -build output/
17# Upload output/ to GitHub Pages, Netlify, etc
XLog watches your filesystem for changes and automatically refreshes your browser. Here’s what triggers a reload:
Triggers hot-reload:
Does NOT trigger reload:
How it works:
Performance tip: XLog only watches markdown files by default. If you have thousands of files, this stays fast.
XLog is Git-native, meaning it works perfectly with version control.
1# Initialize Git in your notes directory
2cd ~/notes
3git init
4
5# XLog ignores .git automatically
6xlog
7
8# Add and commit as you write
9git add .
10git commit -m "Add quantum computing notes"
11
12# Push to remote backup
13git remote add origin git@github.com:yourname/notes.git
14git push -u origin main
You can create a script that auto-commits after edits:
1#!/bin/bash
2# save-and-commit.sh
3
4# Watch for changes and auto-commit
5while inotifywait -r -e modify,create,delete ~/notes; do
6 cd ~/notes
7 git add .
8 git commit -m "Auto-commit: $(date)"
9done
Note: Auto-commit is optional. Many users prefer manual commits for meaningful messages.
1# Create draft branch
2git checkout -b drafts
3
4# XLog shows same content, just different Git branch
5xlog
6
7# Publish by merging to main
8git checkout main
9git merge drafts
1# Device 1: Push changes
2cd ~/notes
3git add .
4git commit -m "Update notes"
5git push
6
7# Device 2: Pull changes
8cd ~/notes
9git pull
10# XLog automatically detects changes and reloads
Many users use Obsidian for mobile editing and XLog for publishing:
1# Point XLog to Obsidian vault
2xlog -source ~/Obsidian/MyVault
3
4# Edit in Obsidian on phone/tablet
5# XLog picks up changes automatically
6# Publish static site from XLog
1# Sync folder across devices
2# XLog watches for filesystem changes
3# Works with any sync solution
Problem: Clicking “Edit” does nothing
Solutions:
which code or which vimxlog -editor "vim"Problem: Saved file but browser doesn’t update
Solutions:
Problem: Can’t edit files
Solutions:
ls -lachmod 644 *.mdUse clear folder structure:
notes/
index.md # Homepage
daily/ # Daily notes
projects/ # Project-specific notes
reference/ # Reference material
public/ # Images, assets
Use frontmatter for metadata:
1---
2title: My Research Paper
3tags: [research, physics]
4date: 2026-05-07
5---
Use descriptive page names:
[quantum-computing-basics](/quantum-computing-basics)[qc1](/qc1)Create hub pages:
For large knowledge bases (1000+ pages):
.gitignore for files you don’t need in Gitxlog -readonly if you don’t need editingXLog workflow = Your Editor + Live Preview + Git
Not:
This workflow gives you the best of both worlds: powerful editing tools and modern preview experience.