Bootstrap home-apps and fix Emacs/iPad integration issues. Changes: - Added home-apps-session-summary.md documenting Emacs config fixes - Updated CLAUDE.md session history with 2026-04-12 entry - Added home-apps to VPS instance list in CLAUDE.md Repository: http://100.120.125.113:3000/pdm/homelab-agents Next Session Focus: Test mermaid rendering on iPad end-to-end
4.2 KiB
4.2 KiB
Session Summary - home-apps
Date: 2026-04-12 Hostname: home-apps Repository: homelab-agents (shared)
Session Overview
Debugging and fixing Emacs configuration to work correctly on the Linux VM accessed via terminal from an iPad. Config is authored on a Mac and synced to the VM via Syncthing.
Accomplishments
Emacs Init Error Fixed (flashcard-config.el)
- Identified
void-variable flash-card-mode-maperror on startup - Root cause: mismatched parenthesis caused
(define-key flash-card-mode-map ...)to fall outside theuse-packageblock and execute before the package loaded - Fixed by moving the closing
)to after the seconddefine-key
Cross-Platform Load Paths Fixed
flashcard-config.elandtask-config.elboth referenced~/config/sam_emacs_packages/which does not exist on this VM (packages live at~/sam_emacs_packages/)- Applied the conditional
darwin/Linux pattern:(add-to-list 'load-path (expand-file-name (if (eq system-type 'darwin) "~/config/sam_emacs_packages/<pkg>" "~/sam_emacs_packages/<pkg>")))
secrets.el Symlink Added
init.elloadssecrets.elviauser-emacs-directorybut no symlink existed- Added:
~/.emacs.d/secrets.el→~/emacs_config/secrets.el
ELPA Package Visibility Fixed (ob-mermaid)
- On Mac,
~/.emacs.dsymlinks to~/config/emacs_configso packages install into~/emacs_config/elpa/. On the VM,~/.emacs.d/elpa/is a separate real directory. - Fixed by adding
~/emacs_config/elpa/topackage-directory-listinpackage-setup.elbefore(package-initialize), Linux-only
mermaid-mode Added
- Added
mermaid-modealongside existingob-mermaidinorg-base.el - Guarded by same
(when my/mmdc-path ...)check — only loads ifmmdcis available - Reuses
my/mmdc-pathvariable for cross-platform CLI path
Puppeteer Sandbox Fix (VM only)
mmdcuses headless Chromium which requires sandboxing — blocked on this Linux VM- Created
~/.config/mermaid/puppeteer-config.jsonwith{"args": ["--no-sandbox"]} org-base.eldetects this file at load time and setsob-mermaid-puppeteer-configandmermaid-flagsaccordingly; Mac is unaffected (file doesn't exist there)
Notion Credentials Investigated
- "Notion Task DBID not set" error traced to credentials path resolution
notion-config.elresolves path relative to parent ofuser-emacs-directory(following symlinks): Mac →~/config/credentials/, VM →~/credentials/- File confirmed present at
~/credentials/notion-credentials.env— already synced
.netrc Set Up for Gitea
- Bootstrap script at
https://gitea.pdmarf.co.ukrequired authentication - Created
~/.netrcwith API token for both the public domain and internal IP (100.120.125.113) — git operations inside the bootstrap use the internal address - Documented in
~/netrc-explainer.org
Key Decisions
- Conditional load paths rather than VM-only overrides — keeps one config file working on both platforms
package-directory-listrather than symlinking elpa directories — safer, non-destructive- Puppeteer config file as feature flag — presence of the file enables the workaround, absence is safe
.netrcfor Gitea auth — token stored once, not embedded in scripts or history
Files Modified
| File | Change |
|---|---|
my-packages/flashcard-config.el |
Fixed paren bug; conditional load path |
my-packages/task-config.el |
Conditional load path |
my-packages/package-setup.el |
Added ~/emacs_config/elpa to package-directory-list on Linux |
my-packages/org-base.el |
Added mermaid-mode; Puppeteer config detection |
~/.emacs.d/secrets.el |
New symlink → ~/emacs_config/secrets.el |
~/.config/mermaid/puppeteer-config.json |
New file, VM only |
~/.netrc |
New file, Gitea credentials |
~/netrc-explainer.org |
New documentation file |
Next Steps
- Restart Emacs on Mac to let
:ensure tinstallmermaid-modefrom MELPA - Test
mermaid-compileand Babel#+begin_src mermaidblocks on the iPad - Verify Notion Tasks opens cleanly after credentials fix