how to use this repo as a blog template
Closed this issue · 4 comments
Dear,
I'm trying to use this notes repository as a blog template.
I went through the "contribution-guide.tm" and was able to generate HTML files locally.
But I did not figure out how "update-website" and "notes-tools.scm" were used.
It seems that Scheme functions in "notes-tools.scm" are to take care of the files "list-articles.tm" and "notes.atom".
Any hints?
Thank you very much,
Hongying
The "update-website" script is tuned to my setup, you have to change it for you. It essentially runs TeXmacs, loads the "notes-tools.scm" scheme script and run a particular function which generated the two automatic documents, as you have guessed. How to modify it depends essentially on which OS you are working and where you have installed TeXmacs.
To tune the scheme script you have to modify the two lines
(define (src-dir) (url->string (url-expand "$PWD/src")))
(define (dest-dir) (url->string (url-expand "$PWD/docs")))
to point to the directory where you have your sources and where you want to put the generated HTML files.
Thank you!
I just modified update-website
and everything works.
# I replaced the first line in the following by the other two.
# TEXMACS_PATH=$HOME/t/svn-src/TeXmacs $HOME/t/svn-src/TeXmacs/bin/texmacs.bin \
TEXMACS_PATH=/Applications/TeXmacs.app/Contents/MacOS/TeXmacs
/Applications/TeXmacs.app/Contents/MacOS/TeXmacs -x \
Additional notes for those who are interested:
- To modify the blog template header, open any
tm
file insrc/
, edit the style "Notes", and save it asnotes.ts
insrc/
. - For Atom feed generation, it's necessary to adjust functions
output-article-feed
andmake-atom-entry
to your domain name innotes-tools.scm
.
Great! Please let us know if you publish a website using TeXmacs, we can add to the list of blogs.