From 35483ab1d59bf4da5d432e1a14716d25b2430a19 Mon Sep 17 00:00:00 2001 From: Yuchen Pei Date: Thu, 14 Apr 2022 21:19:57 +1000 Subject: minor update --- microposts/boyer-moore.org | 4 ++-- posts/2018-12-02-lime-shapley.org | 6 +++++- publish.el | 30 ++++++++++++++++++------------ 3 files changed, 25 insertions(+), 15 deletions(-) diff --git a/microposts/boyer-moore.org b/microposts/boyer-moore.org index 6298454..8c67b74 100644 --- a/microposts/boyer-moore.org +++ b/microposts/boyer-moore.org @@ -7,7 +7,7 @@ The algorithm for finding the majority of a sequence of elements]] falls in the category of "very clever algorithms". -#+begin_example +#+begin_src c++ int majorityElement(vector& xs) { int count = 0; int maj = xs[0]; @@ -18,4 +18,4 @@ the category of "very clever algorithms". } return maj; } -#+end_example +#+end_src diff --git a/posts/2018-12-02-lime-shapley.org b/posts/2018-12-02-lime-shapley.org index a7a8491..a0c09bc 100644 --- a/posts/2018-12-02-lime-shapley.org +++ b/posts/2018-12-02-lime-shapley.org @@ -7,7 +7,11 @@ # no Back-Cover Texts. You should have received a copy of the GNU # Free Documentation License. If not, see . -# This work is licensed under the Creative Commons Attribution-ShareAlike 4.0 International License. To view a copy of this license, visit http://creativecommons.org/licenses/by-sa/4.0/ or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA. +# This work is licensed under the Creative Commons +# Attribution-ShareAlike 4.0 International License. To view a copy of +# this license, visit http://creativecommons.org/licenses/by-sa/4.0/ +# or send a letter to Creative Commons, PO Box 1866, Mountain View, CA +# 94042, USA. #+title: Shapley, LIME and SHAP diff --git a/publish.el b/publish.el index 4b7274c..e3aaa6f 100644 --- a/publish.el +++ b/publish.el @@ -19,6 +19,7 @@ (package-initialize) (require 'ox-publish) +(require 'htmlize) (defvar this-date-format "%Y-%m-%d") @@ -91,6 +92,8 @@ PUB-DIR is when the output will be placed." (if (equal "../pages/microblog.org" (file-name-nondirectory filename)) (org-html-publish-to-html plist filename pub-dir))) +(setq org-src-fontify-natively t) + (setq org-publish-project-alist '(("posts" :base-directory "posts" @@ -113,6 +116,7 @@ PUB-DIR is when the output will be placed." :html-postamble me/html-postamble :html-mathjax-options ((path "/js/mathjax/MathJax.js?config=TeX-AMS_CHTML")) :html-mathjax-template "" + :htmlized-source t ) ("microposts" :base-directory "microposts" @@ -132,6 +136,7 @@ PUB-DIR is when the output will be placed." :html-postamble me/html-postamble :html-mathjax-options ((path "/js/mathjax/MathJax.js?config=TeX-AMS_CHTML")) :html-mathjax-template "" + :htmlized-source t ) ("pages" :base-directory "pages" @@ -152,21 +157,22 @@ PUB-DIR is when the output will be placed." :html-prefer-user-labels t :html-mathjax-options ((path "/js/mathjax/MathJax.js?config=TeX-AMS_CHTML")) :html-mathjax-template "" + :htmlized-source t ) ("css" - :base-directory "css" - :base-extension "css" - :publishing-directory "site/css" - :publishing-function org-publish-attachment - :recursive t - ) + :base-directory "css" + :base-extension "css" + :publishing-directory "site/css" + :publishing-function org-publish-attachment + :recursive t + ) ("js" - :base-directory "js" - :base-extension "js" - :publishing-directory "site/js" - :publishing-function org-publish-attachment - :recursive t - ) + :base-directory "js" + :base-extension "js" + :publishing-directory "site/js" + :publishing-function org-publish-attachment + :recursive t + ) ("assets" :base-directory "assets" :base-extension any -- cgit v1.2.3