org-odt.el: Create mimetype file towards the end of export
* contrib/lisp/org-odt.el (org-odt-init-outfile): Don't create mimetype file here. (org-odt-save-as-outfile): Create mimetype file here. Note that this routine gets called towards the end of the export just before files are zipped.
This commit is contained in:
parent
c08183d043
commit
82cf5d59e7
|
@ -1422,10 +1422,6 @@ MAY-INLINE-P allows inlining it as an image."
|
||||||
(save-excursion
|
(save-excursion
|
||||||
(insert (mapconcat 'identity (cdr org-export-odt-manifest-lines) "\n"))))
|
(insert (mapconcat 'identity (cdr org-export-odt-manifest-lines) "\n"))))
|
||||||
|
|
||||||
;; mimetype
|
|
||||||
(with-current-buffer (find-file-noselect mimetype-file t)
|
|
||||||
(insert "application/vnd.oasis.opendocument.text"))
|
|
||||||
|
|
||||||
;; styles file
|
;; styles file
|
||||||
;; (copy-file org-export-odt-styles-file styles-file t)
|
;; (copy-file org-export-odt-styles-file styles-file t)
|
||||||
|
|
||||||
|
@ -1451,6 +1447,10 @@ visually."
|
||||||
|
|
||||||
(defvar hfy-user-sheet-assoc) ; bound during org-do-lparse
|
(defvar hfy-user-sheet-assoc) ; bound during org-do-lparse
|
||||||
(defun org-odt-save-as-outfile (target opt-plist)
|
(defun org-odt-save-as-outfile (target opt-plist)
|
||||||
|
;; create mimetype file
|
||||||
|
(write-region "application/vnd.oasis.opendocument.text" nil
|
||||||
|
(expand-file-name "mimetype"))
|
||||||
|
|
||||||
;; write meta file
|
;; write meta file
|
||||||
(org-odt-update-meta-file opt-plist)
|
(org-odt-update-meta-file opt-plist)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue