LRE

When debugging or poking around in a project, I often do several things

LRE makes these things easy.

Basics

Start LRE with the lre command at the command prompt.

On startup, LRE

Additional Features

You can monitor additional directories and file types.

To monitor additional directories, add them in your .lre file. This will watch for .rb files.

LRE.add_watch_dir "/code/something", "/code/something_else"

To monitor addtional file types, add a watch in your .lre file

LRE.watch(".*/run_on_change/.*\.sql") do |f|
  require 'sws'
  str = parse_erb_str(File.read(f))
  SWS.execute_str! str
end

LRE won't automatically pick up on new files, only changed files. Calling LRE.start! will cause new files to be monitored going forward.

LRE.start!

Installing

gem install lre

Other

LRE is short for Little Ruby Environment or nothing, depending on my mood.

Contributing to lre

Copyright © 2011 mharris717. See LICENSE.txt for further details.