config.el require org-roam-export-blog; SPC n r b / SPC n r j config-linux.el firehose ~/dev/elixir/firehose, jekyll ~/Documents/... config-mac.el firehose ~/dev/elixir/firehose, jekyll ~/MyDocuments/... Upstream sets both roots in the shared config.el. That does not survive the trip: the jekyll checkout is ~/MyDocuments/qwan/sites/qwaneu.github.io on macOS and ~/Documents/qwan/sites/qwaneu.github.io here (both verified to exist). So the roots go to the OS files and the shared half holds only the require and the bindings. Paths are home-relative, and config-local.el can override them if a checkout ever moves. Prefix SPC n r was unused in this config, so no rebinding. Verified in a scratch checkout: the imported suite passes 20/20 (emacs -Q --batch -L qwan -l qwan/org-roam-export-blog.el -l qwan/org-roam-export-blog-test.el -f ert-run-tests-batch-and-exit) and the existing firehose-blog suite still passes 16/16.
36 lines
1.7 KiB
EmacsLisp
36 lines
1.7 KiB
EmacsLisp
;;; config-linux.el --- Linux-specific configuration -*- lexical-binding: t; -*-
|
|
|
|
;; Loaded from config.el on GNU/Linux machines only; config-mac.el is the
|
|
;; macOS counterpart. Anything with a Linux path, a Linux binary, or a
|
|
;; backend that only exists on this box belongs here rather than in the
|
|
;; shared config.el.
|
|
;;
|
|
;; Machine-specific settings that should not be committed at all (API keys,
|
|
;; checkouts in unusual places) belong in config-local.el, which is
|
|
;; gitignored -- see config-local.example.el.
|
|
|
|
;; Elixir language server. The shared config.el used to point eglot at a
|
|
;; macOS path (/Users/willem/.elixir-ls/...), which was silently dead here.
|
|
;; Prefer `expert' if it is installed, else any elixir-ls on PATH, else
|
|
;; leave eglot alone rather than configuring a server that cannot start.
|
|
(with-eval-after-load 'eglot
|
|
(let ((server (cond ((executable-find "expert")
|
|
'("expert" "--stdio"))
|
|
((executable-find "language_server.sh")
|
|
(list (or (executable-find "bash") "sh")
|
|
(executable-find "language_server.sh"))))))
|
|
(when server
|
|
(setf (alist-get '(elixir-mode elixir-ts-mode heex-ts-mode)
|
|
eglot-server-programs
|
|
nil nil #'equal)
|
|
server))))
|
|
|
|
;; Blog export destinations. Upstream keeps these in the shared config.el as
|
|
;; ~/MyDocuments/..., which does not exist on this machine; here the jekyll
|
|
;; checkout lives under ~/Documents/.... Both are home-relative, so if a
|
|
;; checkout ever moves, override it in config-local.el.
|
|
(setq org-roam-export-blog-firehose-root "~/dev/elixir/firehose"
|
|
org-roam-export-jekyll-root "~/Documents/qwan/sites/qwaneu.github.io")
|
|
|
|
;;; config-linux.el ends here
|