emacsorphanage / org-page Goto Github PK
View Code? Open in Web Editor NEW[INACTIVE] A static site generator based on Emacs and org mode.
[INACTIVE] A static site generator based on Emacs and org mode.
please implement RSS subscription.
the publication directory "blog" is missing from current entire URL path.
Refine the theme templates, seperate html code from lisp code.
In function op/publish-changes
, there is a code snippet:
(when (member org-file upd-list)
(op/publish-modified-file
(car file-attr-list) pub-root-dir ext-plist))
org-file
is always like "/home/xxx/ab.org", but upd-list
is always like (... "~/ab.org" ...), so no org file can match the string and of course no files are published.
The URI of index and about should always be /
and /about/
, they should cannot be customized by #+URI
property.
twitter/bootstrap provides some concise css/javascript solution.
I'll try to add this in a few weeks.
Hi Kelvin,
I find your work really helpful! Is org-page currently compatible with the new release of Org Mode 8.0? Thanks very much!
C Wu
if there is no default index/about page, generate both.
Update descriptions for op-export.el
, op-enhance.el
, op-vars.el
.
Especially the last.
the variables op/publish-site-url
and op/personal-disqus-shortname
are required, while doing initialization, verify them to ensure they are not empty.
Corresponding variables, e.g. op/html-head-template
, are set when defined. Any changes to op/theme
later cannot affect these variables, so theme change will not take effect.
In order to help understanding how org-page works, some org files should added into the repos.
when you change the entire site to a new theme, you need to republish all files. The op/republish all function just republish all *.org files one by one.
I think it's better to use let instead of let* when possible. I don't know whether elisp has this coding style limit, but I do remember that common lisp recommand using let instead of let* when possible.
In common lisp, let has more clear semantic and better performance(for example, let can do parallel assignment while let* must do sequential assignment.
I'll do some code refinement this week.
Every time when using op/repository-directory
, (file-name-as-directory op/repository-directory)
is required to ensure correctness. Ensure it before publication will save many efforts, so does many other directories, like pub-root-dir
, etc.
while publishing, the original org files are also published (just htmlized), add the corresponding link to each html-exported page.
Table Of Contents(TOC) is suitable to be a sidebar-like section, see:
http://orgmode.org/worg/
I've implement the basic theme style in my local branch, and I expect that this feature will be complete in this week.
because tag org files are treated as normal to-be-published files, they are also included while generating sitemap org file and recent posts org file, please remove them from the included file list.
Ref: http://www.v2ex.com/t/53456#reply8
- item1
- item2
- item3
became
- item1 -item2 -item3
Add google analytics support, like disqus.
As the title described, make this function interactive.
code block in exported org html files is just long long htmlized plain text. When code is long, it should make it possible collapable and copiable.
I'm not sure whether or not javascript can do this, but I'll try it.
The last modification date obtained according to file's attribute is not reliable, may consider using git's last modification date instead.
code snippets between #+begin_src
and #+end_src
are converted into one line, but code snippets defined after colon :
are not affected.
if there is a space in file name, op/git-last-change-date
will return nil, so consider to quote the filename to avoid this condition.
links to the tag pages that current post used should be added to the footer of the post.
by default the html page charset is "iso-8859-1", should use "utf-8" instead, otherwise DBCS will show as garbage characters.
publication depends on the org files of specified branch, change to other branches will lead to empty publication.
blog index/wiki index generation function is needed, and then the links to blog and wiki can be shown on header.
the name and github link are hard-coded, fix them.
currently "category" does not make much sense, when reorganizing the project structure, make a new directory with the name of the file's category, and put the file in it, so, at last a file will have the following path:
<op/root-directory>/src/<category>/2012/11/25/<file-title>/index.org
I think this kind of structure is much better.
currently the name is "html", but I think "blog" is much better.
hi, kelvin:
I've found template with elisp format-spec is not flexible enough, and it is not user-friendly for template designers(for example, %d, %a is not as clearly understandable as {{date}}, {{author}}).
How do you think that we turn the simple format-spec based template to mustache-based template strategy? There're already some simple elisp library that support mustache, see:
I know this new strategy will put on some new dependencies on org-page, but I think it worth it in the long run. I've also found some good elisp libraries which may be useful:
I think these library should make org-page's code simpler and shorter, with the cost of importing extra dependencies.
Wait for you advice.
The <blockquote>
tag has no special effect, add css style for it (default theme).
The encoding of generated files, such as files under folder "tags", is "ISO-8859-1", so DBCS on this kind of page will show as garbage character, change it to "UTF-8".
Currently the section about disqus is hard coded, implement it.
I've found some code in org-page.el is 160 characters long, that makes code reading on laptop difficult.
As a convention, I'll try to make some refactoring and restyle to the code, if you agree with me, kelvinh.
there should be a common page title, except navigation bar and post title.
After exporting, all html buffers are opening, close them.
the variable op/publish-search-url
and op/publish-site-url
are almost the same, merge them into one.
Garbage characters occur when title has DBCS, but post contents only contain ASCII.
On branch office, example code @<a href="/blog/post/">Title@</a>
is transformed into:
Title, which is an improper transformation.
when publishing project the first time, the generated org files of tags and recent posts are not published to html.
reason:
the to-be-published file list is generated before the tags and recent posts org file generated, so they are not included in the file list, update the file list after the org files generation can solve this problem.
The definition of op/do-publication
is changed, update README to make them match.
--edit--
New function op/new-repository
is added, add section in README to introduce it.
currently the about page "about.org" is treated as a normal post, so it is generated as a blog post, not the about page.
see http://freemind.pluskid.org/misc/printable-version-pdf-of-this-blog/.
And I think pdf export is very easy in org file without CJK. There may be some work with CJK support, but this is not that hard since xecjk in texlive is quite easy to use.
This feature should be a addon for the entire site, and you can enable/disable it at any time. All you need to do is just op/republish the whole project.
As others suggested, "Convention over Configuration", so variable like op/css-list
makes no use. delete variables like this.
I've dived into the code and find it promising using the new git-based publishing strategy. But they are some requirement which is much be set before you can publish the project. Say, let project-dir be "/tmp/op-pub", then "/tmp/op-pub" must be:
What op/new-project do is just build a basic project structure based on which the users can add new org files and publish it directly.
@ tag in org file does not turn the text in it into bold.
Remove the meta tag generation time, otherwise publication everytime will update the time for auto generated tag pages and git will consider them as modified, in fact, they are actually not modified.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.