Linux Commands Examples

A great documentation place for Linux commands


an embedded Ruby language interpreter


erb1.8 [switches] [inputfile]

add an example, a script, a trick and tips

: email address (won't be displayed)
: name

Step 2

Thanks for this example ! - It will be moderated and published shortly.

Feel free to post other examples
Oops ! There is a tiny cockup. A damn 404 cockup. Please contact the loosy team who maintains and develops this wonderful site by clicking in the mighty feedback button on the side of the page. Say what happened. Thanks!


erb > README.txt
echo "<%= render(:partial => 'form' ) %>"
cd ../app/views/documents
cp edit.html.erb edit.html.erb.original
cp edit.html.erb edit.html.erb.original
cp _form.html.erb _form.html.erb.original
cp index.html.erb index.html.erb.original
cp new.html.erb new.html.erb.original


erb interprets a Ruby code embedded text file. For example, erb enables you to embed a Ruby code to a HTML file. A Ruby block starts with ’<%’ and ends with ’%>’. erb replaces the block with its output. If ’<%’ is followed by ’=’, eRuby replaces the block with a value of the block. If ’<%’ is followed by ’#’, the block is ignored as a comment.



print ruby script


print ruby script with line number


enables verbose mode


set debugging flags (set $DEBUG to true)

-r library

load a library

-K kcode

specifies KANJI code-set (euc or sjis) or UTF-8 (utf8)

-S safe_level

set $SAFE (0..4)

-T trim_mode

specify trim_mode (0..2)


disregard the lin which starts in "%"

see also



This document stands on eruby(1) which is written by Shugo Maeda <>.

How can this site be more helpful to YOU ?

give  feedback