Skip to content

Latest commit

 

History

History
23 lines (13 loc) · 2.41 KB

README.md

File metadata and controls

23 lines (13 loc) · 2.41 KB

decorators make people think they're smart, but nobody uses them regularly

Python Decorators

On a whim, I decided I was brave enough to give a presentation at EdmontonPy before I went back home to Ottawa. I also decided to give the presentation via Emacs. Granted, I spent several hours learning about Emacs Lisp and org-mode, but it was a ton of fun once I got everything working.

The full org-mode source of the presentation can be viewed online via GitHub, which works reasonably well. If you download that file, you can open it in Emacs and execute all the code examples and stuff.

After several hours of fiddling, I managed to export the presentation to S5, using the exporter in Org 8's contrib files. I had to manually edit the output a bit - I'm going to write a blog post about the steps involved and I'll link to it here when I'm done.

Anyway, you should soon be able to view the presentation on the project page for this repository.

Technical notes

I used a script made in AutoHotKey to turn my PowerPoint-focused presenter remote into something actually useful. You can see that here.

If you're curious, my Emacs setup is available. I used org-present to do the heavy lifting. Before running the examples, you'll want to eval the code blocks under the "Setup" heading.

You'll want to add some hooks to org-present-mode so that it's more presentation-ish - something like this. This is a bit updated from what I used for the decorators talk.

For the decorators talk, I recorded a keyboard macro that would execute a code block and then jump over to its results. It worked surpringly well! But I've since replaced it with a bit of elisp. exec-next-plus-jump-to-result looks for a Clojure code block that is putting its results into an Org block, executes that code, then jumps down to the block.