On May 13, 2009, at 12:04 PM, Sebastian Rose wrote: > > I like the idea of publishing the sources. I have just pushed a change which implements org-publish-org-to-org, so you should be able to use this in a publishing setup. It is also possible to get an htmlized version of the file. The way to use this would be to specify two publishing functions, and to specify the kinds of source file representations with parameters in org-publish-alist, like this: :publishing-function (org-publish-org-to-html org-publish-org-to-org) :plain-source t :htmlized-source t for a file file.org, this would give you both file.org and file.org.html in the publishing directory. In both files, archived trees, commented trees and trees excluded by tags from export would have been removed. The html version will look just like your org buffer in Emacs. If you want to use this in batch processing, you need a CSS file that defines the font colors and set it's location in `org-export-htmlized- org-css-url'. The CSS file can be generated in an interactive Emacs session with M-x org- export-htmlize-generate-css. - Carsten > > Shouldn't we do something like this on worg too? > > It's amazing to see the too files side by side - both perfectly > readable - visible simplicity and a great source of examples for > (potentially new) users. > > BTW: it would be real fun to tranform links for this purpose, so that > visitors could browse the published org sources just like in emacs. > > > > We could as well this here > > [[http://repo.or.cz/w/Worg.git?a=blob;f=org-tutorials/org-publish-html-tutorial.org > ][Source > of this file]] > > > Maybe in the tutorial index (e.g.)? > > > ... > > * Publishing org to html > #+ATTR_HTML: title="See sources of that file (git repo on repo.or.cz)" > [[http://repo.or.cz/w/Worg.git?a=blob;f=org-tutorials/org-publish-html-tutorial.org > ][(src)]] > > .... > > > Sebastian > > > Bernt Hansen writes: >> Carsten Dominik writes: >> >>> On May 13, 2009, at 3:50 AM, Bernt Hansen wrote: >>> >>>> Rick Moynihan writes: >>>> >>>>> Another comment (and this goes for many documents published in >>>>> org-mode) is that it would be nice if the HTML file could link >>>>> to an >>>>> online copy of the raw org file. >>>> >>>> More thoughts along this line... >>>> >>>> The only downside of doing this automatically is if you >>>> include :noexport: tags or COMMENT on headlines to prevent export >>>> (say >>>> you have information you don't want out on the net. >>>> >>>> I wouldn't want the source file automatically published always. >>>> I'm >>>> like to be able to control that from some org-publish >>>> configuration. >>> >>> I guess it would be relatively easy to write a function >>> `org-publish-org-to-org' which would remove these sensitive >>> parts and could be used as as :publishing-function in a setup >> >> That works for me :) I prefer to post my source with the published >> files for most things -- my old publishing method (before switching >> to >> org-mode) used to do that (without the noexport options -- since it >> had >> no concept of not publishing everything). >> >> -Bernt