#pdflatex --shell-escape -interaction=batchmode Lecc01.tex
#pdflatex --shell-escape -interaction=batchmode Lecc01.tex
#latexmk -c Lecc01.tex
#pdflatex --shell-escape -interaction=batchmode Lecc02.tex
#pdflatex --shell-escape -interaction=batchmode Lecc02.tex
#latexmk -c Lecc02.tex
#pdflatex --shell-escape -interaction=batchmode Lecc03.tex
#pdflatex --shell-escape -interaction=batchmode Lecc03.tex
#latexmk -c Lecc03.tex
#pdflatex --shell-escape -interaction=batchmode Lecc04.tex
#pdflatex --shell-escape -interaction=batchmode Lecc04.tex
#latexmk -c Lecc04.tex
#pdflatex --shell-escape -interaction=batchmode Lecc05.tex
#pdflatex --shell-escape -interaction=batchmode Lecc05.tex
#latexmk -c Lecc05.tex
#pdflatex --shell-escape -interaction=batchmode Lecc06.tex
#pdflatex --shell-escape -interaction=batchmode Lecc06.tex
#latexmk -c Lecc06.tex
#pdflatex --shell-escape -interaction=batchmode Lecc07.tex
#pdflatex --shell-escape -interaction=batchmode Lecc07.tex
#latexmk -c Lecc07.tex
#pdflatex --shell-escape -interaction=batchmode Lecc08.tex
#pdflatex --shell-escape -interaction=batchmode Lecc08.tex
#latexmk -c Lecc08.tex
#pdflatex --shell-escape -interaction=batchmode mortality-marriages.tex
#pdflatex --shell-escape -interaction=batchmode mortality-marriages.tex
#latexmk -c mortality-marriages.tex
#pdflatex --shell-escape -interaction=batchmode NombreOscarYConsumoDePetroleo.tex
#pdflatex --shell-escape -interaction=batchmode NombreOscarYConsumoDePetroleo.tex
#latexmk -c NombreOscarYConsumoDePetroleo.tex
#pdflatex --shell-escape -interaction=batchmode EjercicioIdentificacionModeloARIMA.tex
#pdflatex --shell-escape -interaction=batchmode EjercicioIdentificacionModeloARIMA.tex
#latexmk -c EjercicioIdentificacionModeloARIMA.tex
#pdflatex --shell-escape -interaction=batchmode SegundoEjercicioIdentificacionARIMA.tex
#pdflatex --shell-escape -interaction=batchmode SegundoEjercicioIdentificacionARIMA.tex
#latexmk -c SegundoEjercicioIdentificacionARIMA.tex
#pdflatex --shell-escape -interaction=batchmode IndicePreciosViviendasNuevasYdeSegundaMano.tex
#pdflatex --shell-escape -interaction=batchmode IndicePreciosViviendasNuevasYdeSegundaMano.tex
#latexmk -c IndicePreciosViviendasNuevasYdeSegundaMano.tex
#pdflatex --shell-escape -interaction=batchmode LetrasTesoroAmericano3y6meses.tex
#pdflatex --shell-escape -interaction=batchmode LetrasTesoroAmericano3y6meses.tex
#latexmk -c LetrasTesoroAmericano3y6meses.tex
#pdflatex --shell-escape -interaction=batchmode SerieCuentasFinancierasBE.tex
#pdflatex --shell-escape -interaction=batchmode SerieCuentasFinancierasBE.tex
#latexmk -c SerieCuentasFinancierasBE.tex
(require 'ox-ipynb)
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc01.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc02.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc03.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc04.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc05.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc06.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc07.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc08.org")
jupyter nbconvert --config mycfg-GitHubPages.py --to slides --reveal-prefix reveal.js
jupyter nbconvert --config mycfg.py --to slides
We need a small elisp script to setup and publish it.
(use-package htmlize)
(require 'ox-publish)
(let* ((base-directory "./")
(org-export-with-broken-links t)
(org-publish-project-alist `(("html"
:base-directory ,base-directory
:base-extension "org"
:publishing-directory ,(concat base-directory "docs")
:exclude "Almacen\\|USB\\|docs\\|EjerciciosHide\\|SeriesSimuladas4\\|SeriesSimuladas12\\|Calendario\\|ucarima.*\\|.ipynb_checkpoints\\|00Notas.*\\|org-publisg.*\\|kk.*"
:recursive t
:publishing-function org-html-publish-to-html
:auto-preamble t
:auto-sitemap nil)
("static-html"
:base-directory ,base-directory
:base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|dat\\|mov\\|svg\\|aiff\\|csv\\|gdt\\|inp\\|ipynb\\|html"
:publishing-directory ,(concat base-directory "docs")
:exclude "Almacen\\|USB\\|docs\\|EjerciciosHide\\|SeriesSimuladas4\\|SeriesSimuladas12\\|ucarima.*\\|.ipynb_checkpoints\\|org-publisg.*\\|kk.*"
:recursive t
:publishing-function org-publish-attachment)
;; ... all the components ...
("scimax-eln" :components ("html" "static-html")))))
(org-publish "scimax-eln" t))
Podemos chequear la versión local ejecutando el siguiente bloque
(browse-url "docs/index.html")
rm Lecc*.{pdf,slides.html}
To publish these we go into the html directory, commit all the files and push them to GitHUB.
#git add docs
git commit -m "update"
git push
(require 'ox-publish)
(let* ((base-directory "./")
(public-directory "~/repos/Ectrkk/")
(org-export-with-broken-links t)
(org-publish-project-alist `(("html"
:base-directory ,base-directory
:base-extension "org"
:publishing-directory ,(concat public-directory "docs")
:exclude "docs"
:exclude "Calendario"
:exclude ".ipynb_checkpoints"
:exclude "reveal.js.old"
:exclude "USB"
:recursive t
:publishing-function org-html-publish-to-html
:auto-preamble t
:auto-sitemap t)
("pdf"
:base-directory ,base-directory
:base-extension "org"
:publishing-directory ,(concat public-directory "docs/pdfs")
:exclude "docs"
:exclude "Calendario"
:exclude ".ipynb_checkpoints"
:exclude "reveal.js.old"
:exclude "USB"
:recursive t
:publishing-function org-latex-publish-to-pdf
:auto-preamble t
:auto-sitemap nil)
("static-html"
:base-directory ,base-directory
:base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|dat\\|mov\\|txt\\|svg\\|aiff\\|csv\\|gdt\\|inp\\|ipynb"
:publishing-directory ,(concat public-directory "docs")
:exclude "docs"
:exclude "Calendario"
:exclude ".ipynb_checkpoints"
:exclude "reveal.js.old"
:exclude "USB"
:recursive t
:publishing-function org-publish-attachment)
;; ... all the components ...
("scimax-eln" :components ("html" "static-html" "pdf")))))
(org-publish "scimax-eln" t))
(use-package htmlize)
(require 'ox-publish)
(let* ((base-directory "./")
(org-export-with-broken-links t)
(org-publish-project-alist `(("html"
:base-directory ,base-directory
:base-extension "org"
:publishing-directory ,(concat base-directory "USB")
:exclude "Almacen\\|USB\\|docs\\|EjerciciosHide\\|Calendario\\|ucarima.*\\|.ipynb_checkpoints\\|00Notas.*\\|org-publisg.*\\|*.txt\\|kk.*"
:recursive t
:publishing-function org-html-publish-to-html
:auto-preamble t
:auto-sitemap nil)
("static-html"
:base-directory ,base-directory
:base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|dat\\|mov\\|svg\\|aiff\\|csv\\|gdt\\|inp\\|ipynb\\|html"
:publishing-directory ,(concat base-directory "USB")
:exclude "Almacen\\|USB\\|docs\\|EjerciciosHide\\|ucarima.*\\|.ipynb_checkpoints\\|org-publisg.*\\|*.txt\\|kk.*"
:recursive t
:publishing-function org-publish-attachment)
;; ... all the components ...
("scimax-eln" :components ("html" "static-html")))))
(org-publish "scimax-eln" t))
Configuración para nbconvert (las slides usan ficheros locales)
c = get_config()
c.NbConvertApp.notebooks = ["Lecc01.ipynb",
"Lecc02.ipynb",
"Lecc03.ipynb",
"Lecc04.ipynb",
"Lecc05.ipynb",
"Lecc06.ipynb"]
c.SlidesExporter.reveal_theme = 'solarized'
c.SlidesExporter.reveal_scroll = True
.slides {
width: 90% !important;
}
#jupyter nbconvert --config mycfg.py --to notebook
jupyter nbconvert --config mycfg.py --to slides
#jupyter nbconvert --config mycfg.py --to notebook
jupyter nbconvert --config mycfg.py --to slides --no-input
Configuración para nbconvert (las slides usan ficheros de la web para poder funcionar en GitHubPages)
creating-presentations-with-reveal-and-github-pages
https://github.com/RichardAfolabi/Presentation_js
https://emasuriano.com/til/2024-07-01-create-presentations-from-notebook/
https://github.com/yjwen/org-reveal https://github.com/hexmode/ox-reveal
c = get_config()
c.NbConvertApp.notebooks = ["Lecc01.ipynb",
"Lecc02.ipynb",
"Lecc03.ipynb",
"Lecc04.ipynb",
"Lecc05.ipynb",
"Lecc06.ipynb"]
c.SlidesExporter.reveal_theme = 'solarized'
c.SlidesExporter.reveal_scroll = True
c.SlidesExporter.language_code = 'es'
c.SlidesExporter.mathjax_url = "https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS_HTML"
c.SlidesExporter.jquery_url = "https://cdnjs.cloudflare.com/ajax/libs/jquery/2.0.3/jquery.min.js"
c.SlidesExporter.require_js_url = "https://cdnjs.cloudflare.com/ajax/libs/require.js/2.1.10/require.min.js"
jupyter nbconvert --config mycfg-GitHubPages.py --to slides --reveal-prefix reveal.js --no-input
(require 'ox-ipynb)
(ox-ipynb-export-org-file-to-ipynb-file "Lecc01.org")
(ox-ipynb-export-org-file-to-ipynb-file "Lecc02.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc03.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc04.org")
;(ox-ipynb-export-org-file-to-ipynb-file "Lecc05.org")