diff options
| author | Preston Pan <ret2pop@nullring.xyz> | 2026-03-31 02:25:24 -0700 |
|---|---|---|
| committer | Preston Pan <ret2pop@nullring.xyz> | 2026-03-31 02:25:24 -0700 |
| commit | f17203b32bd1ecb0d908bbf03b9239e2efde59d6 (patch) | |
| tree | 67971ff0cfc50d8e22a2af94d8aee98cdfd4d262 /tests/ci-build-stage-two.el | |
| parent | 42656b6d8e9d433ee9a032605755679157980365 (diff) | |
| parent | 369c079498ffa28dec74a259e7acd69d09a36106 (diff) | |
Merge branch 'qtile'
Diffstat (limited to 'tests/ci-build-stage-two.el')
| -rw-r--r-- | tests/ci-build-stage-two.el | 98 |
1 files changed, 93 insertions, 5 deletions
diff --git a/tests/ci-build-stage-two.el b/tests/ci-build-stage-two.el index aca425d..1b58af4 100644 --- a/tests/ci-build-stage-two.el +++ b/tests/ci-build-stage-two.el @@ -16,6 +16,7 @@ (setq org-html-link-org-files-as-html t) (require (quote htmlize)) +(require 'hl-line) (require (quote nix-mode)) (setq org-html-htmlize-output-type (quote css)) @@ -24,14 +25,22 @@ (defun my-ci-force-fontification () "Ensure the buffer is fully colorized before htmlize touches it." - (font-lock-ensure) - (font-lock-flush) - (font-lock-ensure)) + ;; Do NOT try to syntax-highlight the Frankenstein RSS file + (unless (string-match-p "rss\\.org$" (buffer-file-name)) + (font-lock-ensure))) + +(princ "after ci force fontification\n" (quote external-debugging-output)) +(princ "C\n" 'external-debugging-output) (add-hook 'org-publish-before-export-hook #'my-ci-force-fontification) +(princ "C\n" 'external-debugging-output) + +(princ "please work\n" (quote external-debugging-output)) (face-spec-recalc 'default (selected-frame)) -(when (fboundp 'redisplay) (redisplay t)) +(princ "please work part 2\n" (quote external-debugging-output)) +;; (when (fboundp 'redisplay) (redisplay t)) +(princ "please work part 3\n" (quote external-debugging-output)) (princ (format "THEME CHECK - Default background: %s\n" (face-attribute 'default :background)) @@ -39,5 +48,84 @@ (princ "STEP 6: before publish-all\n" (quote external-debugging-output)) +(setq treesit-auto-install nil) + +;; --- DUMP LOG BUFFERS --- +(let ((warnings-buf (get-buffer "*Warnings*")) + (messages-buf (get-buffer "*Messages*"))) + + (princ "\n========================================\n" 'external-debugging-output) + + ;; 1. Dump Warnings + (if warnings-buf + (with-current-buffer warnings-buf + (princ " DUMPING *Warnings* BUFFER \n" 'external-debugging-output) + (princ "----------------------------------------\n" 'external-debugging-output) + (princ (buffer-string) 'external-debugging-output)) + (princ " No *Warnings* buffer found. \n" 'external-debugging-output)) + + (princ "\n========================================\n" 'external-debugging-output) + + ;; 2. Dump Messages + (if messages-buf + (with-current-buffer messages-buf + (princ " DUMPING *Messages* BUFFER \n" 'external-debugging-output) + (princ "----------------------------------------\n" 'external-debugging-output) + (princ (buffer-string) 'external-debugging-output)) + (princ " No *Messages* buffer found. \n" 'external-debugging-output)) + + (princ "========================================\n\n" 'external-debugging-output)) +;; ---------------------------- + +(require 'pp) ; Pull in the pretty-printer + +(princ "\n========================================\n" 'external-debugging-output) +(princ " DUMPING org-publish-project-alist \n" 'external-debugging-output) +(princ "----------------------------------------\n" 'external-debugging-output) + +;; pp-to-string formats the nested list with proper indentation and line breaks +(princ (pp-to-string org-publish-project-alist) 'external-debugging-output) + +(princ "\n========================================\n\n" 'external-debugging-output) +(setq org-export-use-babel nil) + +(advice-add 'org-publish-file :before + (lambda (file &rest _) + (princ (format "-> Exporting file: %s\n" file) 'external-debugging-output))) + +(advice-add 'org-publish-find-title :before + (lambda (file &rest _) + (princ (format "-> Extracting title for sitemap: %s\n" file) 'external-debugging-output))) + +(advice-add 'org-publish-file :after + (lambda (file &rest _) + (princ (format "<- Finished file: %s\n" file) 'external-debugging-output))) + +(defvar my-sitemap-counter 0) +(advice-add 'org-sitemap-format-entry-xml :before + (lambda (entry &rest _) + (setq my-sitemap-counter (1+ my-sitemap-counter)) + (when (= 0 (mod my-sitemap-counter 20)) + (princ (format " [Sitemap XML] Processed %d files... Current: %s\n" + my-sitemap-counter entry) + 'external-debugging-output)))) + +(advice-add 'org-rss-publish-to-rss :around + (lambda (fn plist filename pub-dir) + (princ (format "[rss] enter %s\n" filename) 'external-debugging-output) + (prog1 (funcall fn plist filename pub-dir) + (princ (format "[rss] leave %s\n" filename) 'external-debugging-output)))) + +(advice-add 'org-icalendar-create-uid :before + (lambda (&rest _) (princ "[rss] before uid\n" 'external-debugging-output))) + +(advice-add 'org-rss-add-pubdate-property :before + (lambda (&rest _) (princ "[rss] before pubdate\n" 'external-debugging-output))) + +(advice-add 'write-file :before + (lambda (&rest _) (princ "[rss] before write-file\n" 'external-debugging-output))) + +(advice-add 'org-export-to-file :before + (lambda (&rest _) (princ "[rss] before org-export-to-file\n" 'external-debugging-output))) + (org-publish-all t) -(org-publish-all nil) |
