Skip to content
ahonor edited this page Sep 23, 2011 · 31 revisions

System Requirements

  • Bash shell and a unix system environment.

Installation

No packaging exists for rerun. For now, simply "git clone" it.

cd /tmp
git clone git://github.com/dtolabs/rerun.git
cd rerun

After it is downloaded, invoke the rerun -help to see usage and version:

banner

Run it without arguments to see a list of installed modules.

$ ./rerun 
[modules]
  stubbs: "Simple rerun module builder"

Successful installation results in a module listing (stubbs module is included by default).

If you care about system packaging (e.g. RPM, DEB), feel free to contribute your ideas. We're also thinking of building rerun modules distribution around git (ala homebrew).

Environment

Update your Bash profile (e.g., .bash_profile, .bashrc) to set the following environment variables.

PATH

Add the path to your rerun executable to your $PATH.

RERUN_MODULES

Rerun checks for an environment variable called $RERUN_MODULES that specifies a directory of rerun modules. If $RERUN_MODULES is not set, rerun checks the current working directory for a subdirectory called "modules".

RERUN_LOGS

Path to directory where rerun will write log files

RERUN_COLOR

Set 'true' if you want ANSI text effects

Single user setup

A single user setup makes sense when rerun commands are all executed by that user. This might be a human's unix account or it could be a "role" account used for administration tasks (eg. deployment procedures).

Example: Single user rerun setup.

export PATH=$PATH:$HOME/.rerun
export RERUN_MODULES=$HOME/.rerun/modules
export RERUN_LOGS=$HOME/.rerun/logs
[ -t 0 ] && export RERUN_COLOR=true

System wide setup

System wide setup can make sense if rerun is used to manage any system task.

If you're sharing a system wide rerun install with other users, be sure they have write access to the RERUN_LOGS directory (e.g., perhaps through group membership). Also, take care to define policy around who can execute rerun and what modules they are allowed to see.

Example: System wide rerun setup.

# Copy rerun to /usr/bin/rerun
export RERUN_MODULES=/var/rerun/modules
export RERUN_LOGS=/var/rerun/logs
export RERUN_COLOR=false

Bash completion

Rerun's listing feature is available through Bash command completion. To enable it, update your .bash_profile with a line like so:

[ -r $HOME/.rerun/bash_completion ] && source $HOME/.rerun/bash_completion

Next steps

See README.md for general usage information.

The stubbs module is included and you'll find it useful to create your own modules.

Clone this wiki locally