From mboxrd@z Thu Jan 1 00:00:00 1970 From: stardiviner Subject: How to also convert org file into htmlized html file in org-publish? Date: Mon, 16 Apr 2018 22:52:16 +0800 Message-ID: <87sh7v5hlr.fsf@gmail.com> Reply-To: numbchild@gmail.com Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:41989) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f85Uf-000256-A8 for emacs-orgmode@gnu.org; Mon, 16 Apr 2018 10:52:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f85Uc-0004Xp-8h for emacs-orgmode@gnu.org; Mon, 16 Apr 2018 10:52:33 -0400 Received: from [183.249.134.91] (port=3126 helo=dark.localdomain) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f85Ub-0004Tk-PL for emacs-orgmode@gnu.org; Mon, 16 Apr 2018 10:52:30 -0400 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: org-mode =2D----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 I want to have Org-mode file converted into HTML, htmlized HTML, and plain = org file. So I have following config: ,---- | (require 'htmlize) | ;; (setq org-html-htmlize-output-type 'css) | | (defvar my-org-publish-directory "~/org-publish/") | | ;; projects definition | (setq org-publish-project-alist | `(("blog-org" | :base-directory ,(concat org-directory "/Website/Blog/") | :base-extension "org" | :recursive t | :publishing-function (org-html-publish-to-html org-org-publish-t= o-org) | :publishing-directory ,(concat my-org-publish-directory "Blog/") | .... | ))) `---- I want to add a function into `:publishing-function` like `htmlize-file`, but got arguments number error: ,---- | Publishing file /home/stardiviner/Org/Website/Blog/2016-04-22 22:54.org u= sing =E2=80=98htmlize-file=E2=80=99 | org-publish-file: Wrong number of arguments: (1 . 2), 3 `---- So how can I use htmlize in org-publish? And I want to add a button "Show Org-mode version" button on every page. How can I add this button in `:html-postamble` of org-publish to link to current page's htmlized Org-mode page? =2D -- [ stardiviner ] don't need to convince with trends. Blog: https://stardiviner.github.io/ IRC(freenode): stardiviner GPG: F09F650D7D674819892591401B5DF1C95AE89AC3 =2D----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEE8J9lDX1nSBmJJZFAG13xyVromsMFAlrUuKEACgkQG13xyVro msPHhAgAuf3CBbyfaK+ylpQ4/NtKHn9gmpspBOdGd4dI6O972iHj83qxSiHxxoIW FrGElq1IkNpJVohOsz6M6SxL6yKlsySLMw/YxVCKhBdWP0R8uxHfKh62fE0Di5SA V7VMYte7wihx+0mpRHzIu0BniwlAgsZcgt77d9svFQsuMLFt+QuRzRQClWi+r7KI ZKZ709YzzY1jBH0bXJ1VUNimgTR7yiig03m2nvLNnTlpUUcTL3XLo/3PuAAqABTQ gbYPEaTxWA8UAB4xpaSnerZPFCiqNCvMEFJU5YcGOtrRIN8SWKr68QMavuuTWK0e fvUhGTf1Ot6oWvwz6tmlIKW5EvngwQ=3D=3D =3DStDU =2D----END PGP SIGNATURE-----