私はlispでそのような関数を構築しました:
(defun set-web-hosting (hosting)
""" this function sets the hosting of web to specific tramp like target """
(setq org-publish-project-alist
'(
("belohrad.ch-notes"
:base-directory "~/SVN/fiweb/"
:base-extension "org"
:publishing-directory hosting
:recursive t
:publishing-function org-publish-org-to-html
:headline-levels 999
:table-of-contents nil
:section-numbers nil
:auto-preamble t
:auto-sitemap t
:auto-postamble nil
:style ""
:sitemap-filename "sitemap.org"
:sitemap-title "Sitemap"
:sub-superscript nil
:author "David Belohrad"
:email "david@belohrad.ch"
)
("belohrad.ch-static"
:base-directory "~/SVN/fiweb"
:base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|mp3\\|ogg\\|swf\\|deb"
:publishing-directory hosting
:recursive t
:publishing-function org-publish-attachment
)
("web" :components ("belohrad.ch-static" "belohrad.ch-notes"))
)))
使えると思って
(set-web-hosting "~/afs/www/org/")
上記のテストディレクトリにターゲットをセットアップし、
(set-web-hosting ".ssh:nlanla@nlsnls.org:/public_html/")
ライフウェブに設定します。
「ホスティング」は関数内で変数として扱われず、「何か他のもの」として扱われるため、これは機能しません。パブリッシングが呼び出されると、次で終了します
org-publish-file: Wrong type argument: arrayp, hosting
:publishing-directory
プロパティを正しく設定するにはどうすればよいですか?