Skip to content
A direct port of Rake to javascript on top of the CommonJS standard.
Find file
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
bin Start adding command line opts, like -T, -P, -D.
lib Switch to JavaScript style. Sorry Francisco.
LICENSE fixes clearing excluded file patterns for clean task
PORTING-NOTES Minor README fix (also poking GitHub to fix zipball downloads)
package.json Version 0.3 at Mon Oct 11 2010 16:49:57 GMT-0700 (PDT)


Jake is a build tool similar to Make and Rake, but written in and for JavaScript. It's a port of Ruby's Rake, which is inspired by the classic [Make](\)) tool.

Currently it runs on the Narwhal server-side JavaScript platform, but is intended to support any compliant CommonJS system as it matures.


The API is very similar to the Rake API, though with JavaScript syntax.

  • jake.task(name, [dependencies], [action])

Declares a task called "name", with an optional array of dependent tasks, and optional function to perform.

  • jake.file(path, [dependencies], [action])

Like task, but only runs the action if the target file ("name") doesn't exist or was last modified before at least on dependency.

  • jake.filedir(path, [dependencies], action)

TODO: better API docs

Example "Jakefile"

var jake = require("jake");

// prints "default":
jake.task("default", function(t) {

// runs tasks "bar" and "baz"
jake.task("foo", ["bar", "baz"]);

// only runs if "bar" is older than "bar.source" or non-existant
jake.file("bar", ["bar.source"], function() {
    // stuff to compile "bar.source" to "bar"

// does nothing

Example Usage

# runs "default" task if no task names are given

# runs "bar", "baz" dependent tasks, then "foo" task
jake foo

# runs "bar", "baz", "foo", and "default" tasks
jake foo default
Something went wrong with that request. Please try again.