Ruby plugin in EasyEclipse

Hi you all,
anybody knows and/or uses Ruby plugin for Eclipse or EasyEclipse? If
not, just don't keep on reading :slight_smile:
If yes... I am writing a simple program:

路路路

---------------------------------
print "Enter your new idea: "
idea = gets
print "I get your idea"
---------------------------------
When I run the program in EasyEclipse nothing appears in the console. I
have to type my idea and then the two "print's" appear together at the
end. Do you know how can I get a real interactive view of the console?
Thanks :slight_smile:

--
Posted via http://www.ruby-forum.com/.

When I run the program in EasyEclipse nothing appears in the console. I
have to type my idea and then the two "print's" appear together at the
end. Do you know how can I get a real interactive view of the console?
Thanks :slight_smile:

Read thg first FAQ and you should get a good explanation and answer to
your question at: Aptana.com | Axway

Parv

路路路

--
Posted via http://www.ruby-forum.com/\.

Parv G wrote:

Read thg first FAQ and you should get a good explanation and answer to
your question at: Aptana.com | Axway

Parv

Thanks! It works! :smiley:
(however, I was not working with that plugin; I was referring to
http://www.easyeclipse.org/site/plugins/rubyeclipse.html\)

I would like, anyway, to see a behaviour such as the one of FreeRIDE,
even though I prefer to write the statement and keep on working with
Eclipse :slight_smile:

路路路

--
Posted via http://www.ruby-forum.com/\.

Well... now I have another problem...

I write:

路路路

********************
def wipe_mutterings_from( sentence )
聽聽聽聽unless sentence.respond_to? :include?
聽聽聽聽聽聽raise ArgumentError, "cannot wipe mutterings from a #{
sentence.class }"
聽聽聽聽end
聽聽聽聽while sentence.include? '('
聽聽聽聽聽聽聽聽open = sentence.index( '(' )
聽聽聽聽聽聽聽聽close = sentence.index( ')', open )
聽聽聽聽聽聽聽聽sentence[open..close] = '' if close
聽聽聽聽end
end

$stdout.sync = true
what_he_said = "But, strangely (em-pithy-dah),I learned upon."
wipe_mutterings_from( what_he_said )
print what_he_said

wipe_mutterings_from( 123 )
print what_he_said
*****************
Theoretically, the console has to show the "what he said" sentence and
then the error... However, it occurs the other way round, even with the
$stdout set to true. Suggestions will be welcome :smiley:

--
Posted via http://www.ruby-forum.com/.

It may be that errors are being sent out of stderr instead of stdout.
In that case you'd also need:

$stderr.sync = true

You can find a list of these global ($) variables here:

Les

路路路

On 7/6/06, Damaris Fuentes <dfl_maradentro@yahoo.es> wrote:

Well... now I have another problem...

I write:

********************
def wipe_mutterings_from( sentence )
    unless sentence.respond_to? :include?
      raise ArgumentError, "cannot wipe mutterings from a #{
sentence.class }"
    end
    while sentence.include? '('
        open = sentence.index( '(' )
        close = sentence.index( ')', open )
        sentence[open..close] = '' if close
    end
end

$stdout.sync = true
what_he_said = "But, strangely (em-pithy-dah),I learned upon."
wipe_mutterings_from( what_he_said )
print what_he_said

wipe_mutterings_from( 123 )
print what_he_said
*****************
Theoretically, the console has to show the "what he said" sentence and
then the error... However, it occurs the other way round, even with the
$stdout set to true. Suggestions will be welcome :smiley:

um...yes...I tried with that variable... and it dind't
work...however...I have tried right now and it already works fine...I
should be doing something wrong... thanks :smiley:

路路路

--
Posted via http://www.ruby-forum.com/.

Well... I am seeing that with stderr it works... but not always...

路路路

--
Posted via http://www.ruby-forum.com/.