On Monday, March 31, 2003, 2:33:07 PM, Jim wrote:

> On Monday, 31 March 2003 at 12:05:23 +0900, "Pe?a, Botp" wrote:
>> 
>> dummier question: Now, how do I load a (script) file to irb (history)?

Try:

  def loadhist(path)
    File.open(path) do |io|
      io.each do |line|
        Readlines::HISTORY << line
      end
    end
  end

I don't know if that will work, or if it's even possible.


>> My initial wants:
>> 
>> 1. I'd like to load & unload scripts in irb.

> Hmm, I've seen posts on how to run a script and then have
> it stop in irb so you could continue interactively. I don't
> know where, just do a google search. It should not be hard
> to find.

That's a dead end, AFAIK.  You can't really interact with your program
much - no local variables.  For anyone who's interested, though, it's
worth a try for yurself; you may find something interesting.

>> 2. I'd like/dream to combine irb, -rdebug, and ri together..

>> [...]
>> liken to what Chad said, I'd like a _textual_ ide :-)

> You may want to search for what has been done with
> vim and emacs.

I'd like what Botp wants as well.  Vim and emacs have some potential,
but FreeRIDE is more likely, just because it's the focal point of
efforts to produce IDE functionality.  It's a shame that the editor
must be implemented when there are two great ones right there, but
that's life.  Vim and emacs both have very impractical "extension"
languages.

Gavin