public
Description: Some rake tasks to build an erlang project
Homepage: http://charpi.net
Clone URL: git://github.com/charpi/erl_rake.git
name age message
file AUTHORS Sat Jan 24 09:19:34 -0800 2009 First public release of rake tasks for erlang ... [charpi]
file README.textile Tue Nov 03 14:21:02 -0800 2009 Change README format [charpi]
file Rakefile Thu Oct 22 12:01:28 -0700 2009 Add release creation task [charpi]
directory lib/ Thu Oct 22 12:01:28 -0700 2009 Add release creation task [charpi]
directory rakelib/ Tue Nov 03 14:12:31 -0800 2009 Fix compatibilty rake rake 0.8.4 [charpi]
README.textile

Description
erl_rake is a set of scripts to build erlang application with ‘rake’.
To demonstrate the use of those scripts, erl_rake comes with sample
applications.

Author
Nicolas Charpentier <open_source@charpi.net>

How to use erlang rake libraries

erl_rake is designed to be used on project using standard OTP
directory layout.

TOP_DIR/
+lib/
+app1/
+src/
+priv/
+doc/
+ebin/

To build your project with rake and erl_rake, you have to put rakelib
directory under your top directory.

Once rakelib directory in place, you have to create 2 files in your TOP_DIR: a
Rakefile and a configuration file named erlang_config.rb
Typical default Rakefile can be:
==


#-ruby-
require ‘rake’

task :default => [“erlang:compile”, “erlang:releases”]


==

and the erlang_config.rb:
==


ERL_TOP=“/usr/local/lib/erlang”
ERLC_FLAGS=""
ERL_FLAGS=""
USE_EMAKE=true
EMAKE_COMPILE_OPTIONS = []

To compile erlang sources you can use Emake or compile files one by
one setting the configuration variable USE_EMAKE to true or false

Tasks

Here is some details about rake tasks to build erlang stuff.

otp:new_application[name]

Creates a new application skeleton.
You can change the version number of the application modifying the
file TOP_DIR/lib//vsn.config.

otp:new_release[name]

Creates a new erlang release skeleton.
You can change the name of the release modifying the file TOP_DIR/lib//vsn.config

erlang:compile

Compile everything and run tests.

erlang:tests[name] and erlang:tests

Runs tests of a given application or on each applications with eunit.
If a file test.desc is found in the test directory of an application,
we will use it as an eunit test description.

erlang:releases

Builds a tarball for each rel file found in the directory tree.
Releases tarball are generated in TOP_DIR/releases

otp:start_local[name] and otp:start_local[name,daemon]

Starts a release in the developper environment.
Release configuration can be provided in the directory
TOP_DIR/lib//release_config

One node started, you can connect to it using TOP_DIR/connect_local.