Non-LaTeX presentations using org-mode – S5 and HTML5 slides

I recently had frustrations with presentations written using MS Powerpoint; I’m not even going to mention KeyNote as it is only available on a Mac. LibreOffice is my WYSIWYG editor on my Linux machine for writing quick and nicely formatted content. I also have MS Office installed on my machine using WINE. I sometimes use Google Docs for presentation when I have to collaborate. Most of the times, viewing MS-generated files on LibreOffice suffices. When it doesn’t work well, I opt for MS Office. However, I recently had to open a powerpoint presentation with an audio link. It didn’t play on LibreOffice and it didn’t play on my WINE MS Office. I started thinking about a possible route for presentation files that are self-contained and cross-platform. PDF comes to mind first, but to do so would mean I have to use Beamer to generate the slides or to use Adobe Acrobat to create the slides. I don’t want to do either as I’m referring to the scenario of creating quick slides.

HTML came to my mind next. I recalled S5. I remember this post which outlines how one could export to S5 using org-mode. I tried it out finally and things work nicely. This tutorial also mentions an alternative method to generate S5 presentations in org-mode based on the org-export-as-s5 function. Hopefully it will be integrated in the MASTER branch of org-mode soon. To embed audio or video, just paste the html code an html chunk, linking the file multimedia file in the current directory. Now the directory could be transferred to any computer and viewed.

I also stumbled on this link, which allows me to export org files to HTML5 slides. I think the latest file is here, with instructions on how to set up in the comments.

With the S5 and HTML5 slides exporting methods in org-mode, now I can make cross-platform presentations very easily using org-mode. I will probably use the HTML5 method as it doesn’t come with any dependencies like the ui directory from S5.

Bash batch script to convert org-mode file to html

I recently read this on reddit. I adapted the script on there to convert multiple org-mode files to html files. If you use it make sure you adapte the location of org-mode and your org.el file. Enjoy.

 <pre class="src src-sh"><span style="color: #ff4500;">#</span><span style="color: #ff4500;">! /bin/</span><span style="color: #00ffff;">bash</span>

## http://www.reddit.com/r/emacs/comments/dy9yt/anyone_know_of_a_script_that_i_can_feed_an/ ## http://www.ibm.com/developerworks/library/l-bash2.html ## http://desk.stinkpot.org:8080/tricks/index.php/2007/02/concatenate-strings-in-bash/ f=“” for file in “$@” do ##emacs –batch -q –no-site-file –eval “(add-to-list ‘load-path “~/.emacs.d/org-mode/lisp/”)” –load $HOME/.emacs.d/org-mode/lisp/org.el –visit ${file} –funcall org-export-as-html-batch f=“${f} –visit ${file} –funcall org-export-as-html-batch” done emacs –batch -q –no-site-file –eval “(add-to-list ‘load-path “~/.emacs.d/org-mode/lisp/“)” –load $HOME/.emacs.d/org-mode/lisp/org.el $f ## use emacsclient, check if running, execute. otherwise u this ## NO, emacsclient takes in elisp argument with –eval, not list list of files (will need to write my own elisp function…not worth effort)

org-mode: outlines & meeting minutes + others (create / export html)

So I’ve recently discovered org-mode for emacs. I don’t need to put much references up as a simple google search for org-mode should yield many references, especially its home page (there, u can find many references to start using org-mode).

It has many features, but what I personally will use often is outlining and taking notes, especially making meeting agendas and meeting minutes [for my youth group]. I love how easy it is to move things around, and especially how you can export it to ascii, latex/pdf, and html; i usually export to html (C-c C-e h or C-c C-e b), and print to pdf.

I don’t think i will use the agenda and calendar system often; even though i love emacs, i rely on google calendar for this stuff since i sync things to my phone, ical (mac), on the web, etc…i have access to my calendar anytime and anywhere. Also, org-mode has a great html export, has a great table mode (for latex AND html). you can reference things very easily (html), and can create html projects. I might consider doing this for some of my websites in the near future (although i am following in love w/ google sites, it is not 100% suitable for all situations).

This is what I have in my .emacs file for org-mode:

<pre class="src src-sh">;; Org-mode settings

(require ‘org-install) (require ‘org) (add-to-list ‘auto-mode-alist ‘(“\.org$” . org-mode)) (global-set-key “\C-cl” ‘org-store-link) (global-set-key “\C-ca” ‘org-agenda) (global-font-lock-mode 1) ;; turn on soft wrapping mode for org mode (add-hook ‘org-mode-hook (lambda () (setq truncate-lines nil))) (setq user-mail-address “vinhdizzo@gmail.com”)

Here is a video that the creator of org-mode gave at google corp:

NOTE: On my Mac, I’m using carbon emacs (22), and it comes with a very OLD version of org-mode. I had to: delete the org files in Applications/Emacs.app/Contents/Resources/lisp/textmodes and download and install the new org-mode. I added where files are in (path) into .emacs:

(add-to-list ‘load-path “/usr/local/share/emacs/site-lisp”)

Making my personal website and course websites: iWeb + rsync

So I’ve been using iWeb on my macbook to create my personal webpage and potential course websites. I use it because i don’t really know html, and i don’t think I NEED to learn it right now. Point and click to create them is fine with me for the time being. Actually, I would prefer to create the pages in google sites, and export them to my professional-life host, ie, uci-ics domain. However, this option isn’t quite available from google yet.

My main webpage is http://www.ics.uci.edu/~vqnguyen/, and from there, i can have my personal homepage and course websites hosted. However, when I use iweb to publish multiple sites to the same destination via the sftp option, things get funny because iweb puts a default index.html file in each directory, and this file directs u to a page. As i upload multiple sites to that one root domain, re-direction get’s a little fuzzy. I fixed this by uploading the course websites first, then my personal site (root directory) last. Then, with every update, i just use “Publish Site Changes.” However, what if i want to add some more pages? I didn’t like this, and i finally did something about it.

Got my information from UCI’s EEE help on iweb.

Now, what I do is this:

  1. ICS servers: websites are in ~/public_html/
  2. Created ~/public_html and ~/iWebSites on my macbook.
  3. Publish my sites to a local folder, ~/iWebSites, instead of using sftp, one directory for each site.
  4. After every update and publishing to my local folder, i run the following script (supposing my i have two sites, one personal, and one for a class website):
   <pre class="src src-sh"><span style="color: #ff4500;">#</span><span style="color: #ff4500;">! /bin/</span><span style="color: #00ffff;">bash</span>

rsync -progress -av ~/iWebSites/Vinh_Q._Nguyen/ ~/public_html/ rsync -progress -av ~/iWebsites/stat8 ~/public_html/ rsync -progress -av -e ssh ~/public_html/ vqnguyen@chi2.ics.uci.edu:~/public_html/

Now things work great! Good thing i have passwordless ssh!

Next thing to try is html in org-mode (emacs), which i found out through Michael Zeller’s comment on here (he makes his website with it).