mirror of
https://gitlab.com/Titan-C/org-cv.git
synced 2024-11-14 18:48:30 +00:00
more genfiles cleanup
This commit is contained in:
parent
bab87823e2
commit
45d9271165
1 changed files with 22 additions and 15 deletions
37
genfiles.el
37
genfiles.el
|
@ -5,11 +5,29 @@
|
||||||
(with-current-buffer (find-file-noselect "/tmp/install-org.el")
|
(with-current-buffer (find-file-noselect "/tmp/install-org.el")
|
||||||
(emacs-lisp-byte-compile-and-load))
|
(emacs-lisp-byte-compile-and-load))
|
||||||
|
|
||||||
(add-to-list 'load-path cv-cwd)
|
(use-package ox-hugo
|
||||||
|
:ensure t
|
||||||
|
:pin melpa
|
||||||
|
:after ox)
|
||||||
|
|
||||||
(require 'ox-moderncv)
|
(use-package ox-moderncv
|
||||||
(require 'ox-altacv)
|
:load-path cv-cwd
|
||||||
(require 'ox-awesomecv)
|
:init
|
||||||
|
(require 'ox-moderncv)
|
||||||
|
(require 'ox-altacv)
|
||||||
|
(require 'ox-awesomecv))
|
||||||
|
|
||||||
|
(defun export-latex (backend file)
|
||||||
|
(let ((workfile (concat cv-workdir file))
|
||||||
|
(outfile (concat cv-workdir file ".tex"))
|
||||||
|
(pdffile (concat cv-workdir file ".pdf")))
|
||||||
|
(message (format "%s exists: %s" workfile (file-exists-p workfile)))
|
||||||
|
(with-current-buffer
|
||||||
|
(find-file-noselect workfile)
|
||||||
|
(org-mode)
|
||||||
|
(org-export-to-file backend outfile)
|
||||||
|
(shell-command (format "lualatex %s" outfile) "*Messages*" "*Messages*")
|
||||||
|
(copy-file pdffile (concat cv-cwd "/doc/static/" (concat file ".pdf")) t))))
|
||||||
|
|
||||||
(let ((readme (concat cv-cwd "readme.org")))
|
(let ((readme (concat cv-cwd "readme.org")))
|
||||||
(make-directory cv-workdir t)
|
(make-directory cv-workdir t)
|
||||||
|
@ -19,17 +37,6 @@
|
||||||
(org-babel-tangle)))
|
(org-babel-tangle)))
|
||||||
|
|
||||||
(copy-file (concat cv-cwd "doc/smile.png") cv-workdir t)
|
(copy-file (concat cv-cwd "doc/smile.png") cv-workdir t)
|
||||||
|
|
||||||
(defun export-latex (backend file)
|
|
||||||
(let ((workfile (concat cv-workdir file))
|
|
||||||
(outfile (concat cv-workdir file ".tex")))
|
|
||||||
(message (format "%s exists: %s" workfile (file-exists-p workfile)))
|
|
||||||
(find-file workfile)
|
|
||||||
(org-mode)
|
|
||||||
(org-export-to-file backend outfile)
|
|
||||||
(shell-command (format "lualatex %s" outfile) "*Messages*" "*Messages*")
|
|
||||||
(copy-file (concat file ".pdf") (concat cv-cwd "/doc/static/" (concat file ".pdf")) t)))
|
|
||||||
|
|
||||||
(make-directory (concat cwd "/doc/static/") t)
|
(make-directory (concat cwd "/doc/static/") t)
|
||||||
(export-latex 'altacv "altacv.org")
|
(export-latex 'altacv "altacv.org")
|
||||||
(export-latex 'moderncv "moderncv.org")
|
(export-latex 'moderncv "moderncv.org")
|
||||||
|
|
Loading…
Reference in a new issue