«前の日記(2010-12-04(Sat)) 最新 次の日記(2011-01-19(Wed))» 編集
RSS feed
Webサイトとは「つい、うっかりの存在論」である

角谷HTML化計画

「むずかしく考えることはない」と、偉そうに葉巻を振りまわしながら、トレヴィラヌスはいった。「ガリラヤの太守がじつにみごとなサファイアを持っていることは、みんなが知っている。何者かがそれを盗むつもりで、間違ってここへ入ったんだ。ヤルモリンスキーが起きていたので、泥棒は殺さざるをえなかった。どうだね、これで?」
「そのとおりかもしれません。しかし、おもしろくはないですね」と、レンロットは答えた。
J.L.ボルヘス『死とコンパス』(『伝奇集』収録)

2010-12-23(Thu) [長年日記]

■1 Rabbit: a presentation tool for the rubyists and the non-rubyists(for now)

Introduction

In the Japanese-speaking Ruby community, we have some remarkable products made with Ruby. As already mentioned by @makoto_inoue and @a_matsuda, particularly "Big In Japan" products are: tDiary("blog" tool running on this web page), qwik(integrating mailing list and wiki) and Rabbit(presentation tool). Today I'd love to introduce Rabbit to you.

Rabbit is a RD based presentation tool and beyond, created by Kouhei Sutou. You can create presentation slide from plain text(and other sources) and define the stlye of your slide using Ruby (this feature called "theme").

Some Screenshots

"the tortoise and the hare" on the bottom of the slide to timekeeping. Isn't it cool?

Rabbit.png

"Information Window" for presenters also available.

Rabbit-information-window

Same presentation file w/ another theme.

Rabbit-blue-circle

Live examples / Screencasts

The most latest live examples of Rabbit are in RubyConf 2010 video, Keynote by Matz and Ruby Refinements talk by Shugo Maeda. Some short screencasts are also available in project site.

How to Install on Mac OS X with homebrew)

You're lucky if you're using PC-UNIX as your desktop, Rabbit is available in various package management systems(Debian, FreeBSD and Gentoo).

According to Hampton's Ruby Survey, about half of Rubyist is using Mac OS X(me, too). In Mac OS X, Rabbit has macports package and the document titled INSTALL.macosx-macports.en is available on project site. However I'm using Homebrew now. it will be (a little) tough way to install :)

(See also INSTALL.macosx-homebrew.en. Unfortunately I needed some extra steps and great thanks to niku)

NOTE: To install windows environment, there is a INSTALL.win32.en document but it looks like outdated (I have no idea how much it is).

Okay, let's get started.

Step 0: install Ruby and Homebrew

Rabbit works both with 1.8.7 and 1.9.2. This article based on 1.9.2p0.

Step 1: install rdtool

rdtool doesn't seem packaged as rubygems(I don't know why). so you should install via our good old setup.rb:

$ curl http://www.moonwolf.com/ruby/archive/rdtool-0.6.22.tar.gz | tar -zxv
$ cd rdtool-0.6.22
$ ruby setup.rb

Step 2: "brew install" prerequiresites for Rabbit

To hide the title bar from the window on running Rabbit with fullscreen, you should change some Fomula files like as follows(I've posted that to my gists):

Then, brew install:

$ brew install pango
$ brew install cairo
$ brew install gtk+
$ brew install poppler
$ brew install librsvg

Step 3: "gem install" prerequiresites for Rabbit

$ gem install pango
$ gem install cairo
$ gem install gtk2
$ gem install gdk_pixbuf2
$ gem install poppler

Step 4: install Rabbit

Finally, we can install Rabbit via rubygems.

$ gem install rabbit

Usage

To play your presentation:

$ rabbit --type uri http://www.cozmixng.org/repos/rabbit/trunk/sample/rabbit-en.rd

(you can specify a file on your local strage. Rabbit supports various input sources.)

you can get PDF version of your slide via following options:

$ rabbit --print --output-filename=rabbit-en.pdf \
  --type uri http://www.cozmixng.org/repos/rabbit/trunk/sample/rabbit-en.rd

Rabbit has so many useful and crazy features. For more details, see "rabbit --help", README.en and svn repository.

Resources

Enjoy!


This entry is for Ruby Advent Calendar jp-en: 2010.The previous post was from matschaffer:"Making your own Ruby gem" and the next post will be from Nathan Kleyn.


«前の日記(2010-12-04(Sat)) 最新 次の日記(2011-01-19(Wed))» 編集
RSS feed