Tonight, I released an update to iron-term-ansicolor, a library for
IronRuby
that provides console colors for apps like RSpec and Cucumber (Cucumber
already makes use of this, and I bet it would not be too much trouble to
add
to RSpec).
So if a user runs Cucumber on IronRuby, does Cucumber give the right
error message about having to install iron-term-ansicolor? Cucumber used
to say that you had to install win32console. Just checking that
iron-term-ansicolor will be easily discoverable.
From: [email protected]
[mailto:[email protected]] On Behalf Of Will G.
Sent: Friday, February 26, 2010 8:15 PM
To: ironruby-core
Subject: [Ironruby-core] iron-term-ansicolor 0.0.2 Released
Tonight, I released an update to iron-term-ansicolor, a library for
IronRuby that provides console colors for apps like RSpec and Cucumber
(Cucumber already makes use of this, and I bet it would not be too much
trouble to add to RSpec).
Successfully installed term-ansicolor-1.0.4
Successfully installed polyglot-0.3.0
Successfully installed treetop-1.4.4
Successfully installed builder-2.1.2
Successfully installed diff-lcs-1.1.2
Successfully installed json_pure-1.2.2
Successfully installed cucumber-0.6.2
ERROR: While executing gem … (IndexError)
Index was outside the bounds of the array.
C:\temp
[22] » ir -S gem install iron-term-ansicolor
ERROR: While executing gem … (IndexError)
Index was outside the bounds of the array.
C:\temp
[23] »
So if a user runs Cucumber on IronRuby, does Cucumber give the right
error message about having to install iron-term-ansicolor? Cucumber used
to say that you had to install win32console. Just checking that
iron-term-ansicolor will be easily discoverable.
From: [email protected]
[mailto:[email protected]] On Behalf Of Will G.
Sent: Friday, February 26, 2010 8:15 PM
To: ironruby-core
Subject: [Ironruby-core] iron-term-ansicolor 0.0.2 Released
Tonight, I released an update to iron-term-ansicolor, a library for
IronRuby that provides console colors for apps like RSpec and Cucumber
(Cucumber already makes use of this, and I bet it would not be too much
trouble to add to RSpec).
On Mon, Mar 1, 2010 at 1:04 PM, Jim D.
<[email protected]mailto:[email protected]> wrote:
Having issues installing this with ironruby rc2. Anyone else seeing
that? I tried running:
ir -S gem install cucumber iron-term-ansicolor
Pasted output:
[20] » ir -v -e ‘exit’
IronRuby 0.9.4.0 on .NET 2.0.50727.4927
C:\temp
[21] » ir -S gem install cucumber iron-term-ansicolor
Successfully installed term-ansicolor-1.0.4
Successfully installed polyglot-0.3.0
Successfully installed treetop-1.4.4
Successfully installed builder-2.1.2
Successfully installed diff-lcs-1.1.2
Successfully installed json_pure-1.2.2
Successfully installed cucumber-0.6.2
ERROR: While executing gem … (IndexError)
Index was outside the bounds of the array.
C:\temp
[22] » ir -S gem install iron-term-ansicolor
ERROR: While executing gem … (IndexError)
Index was outside the bounds of the array.
C:\temp
[23] »
So if a user runs Cucumber on IronRuby, does Cucumber give the right
error message about having to install iron-term-ansicolor? Cucumber used
to say that you had to install win32console. Just checking that
iron-term-ansicolor will be easily discoverable.
Tonight, I released an update to iron-term-ansicolor, a library for
IronRuby that provides console colors for apps like RSpec and Cucumber
(Cucumber already makes use of this, and I bet it would not be too much
trouble to add to RSpec).
Simply download, then, in the directory you downloaded to:
ir -S gem install iron-term-ansicolor-0.0.2.gem
–
Will G.
On Mon, Mar 1, 2010 at 1:41 PM, Ivan Porto C.
<[email protected]mailto:[email protected]>
wrote:
I also get it when I try to install from a remote location. But
downloading the source and building the gem does work.
On Mon, Mar 1, 2010 at 7:39 PM, Jim D.
<[email protected]mailto:[email protected]> wrote:
C:\Users\jdeville\projects\cucumber
[35] » ir -S gem sources
*** CURRENT SOURCES ***
I can install locally. Perhaps it is a problem with the Gem sources?
C:\Users\will.green\dev\iron-term-ansicolor\pkg>ir -S gem install
iron-term-ansicolor-0.0.2.gem
Successfully installed iron-term-ansicolor-0.0.2
1 gem installed
Installing ri documentation for iron-term-ansicolor-0.0.2…
unrecognized option `–format’
For help on options, try ‘rdoc --help’
–
Will G.
On Mon, Mar 1, 2010 at 1:04 PM, Jim D.
<[email protected]mailto:[email protected]> wrote:
Having issues installing this with ironruby rc2. Anyone else seeing
that? I tried running:
ir -S gem install cucumber iron-term-ansicolor
Pasted output:
[20] » ir -v -e ‘exit’
IronRuby 0.9.4.0 on .NET 2.0.50727.4927
C:\temp
[21] » ir -S gem install cucumber iron-term-ansicolor
Successfully installed term-ansicolor-1.0.4
Successfully installed polyglot-0.3.0
Successfully installed treetop-1.4.4
Successfully installed builder-2.1.2
Successfully installed diff-lcs-1.1.2
Successfully installed json_pure-1.2.2
Successfully installed cucumber-0.6.2
ERROR: While executing gem … (IndexError)
Index was outside the bounds of the array.
C:\temp
[22] » ir -S gem install iron-term-ansicolor
ERROR: While executing gem … (IndexError)
Index was outside the bounds of the array.
C:\temp
[23] »
So if a user runs Cucumber on IronRuby, does Cucumber give the right
error message about having to install iron-term-ansicolor? Cucumber used
to say that you had to install win32console. Just checking that
iron-term-ansicolor will be easily discoverable.
Tonight, I released an update to iron-term-ansicolor, a library for
IronRuby that provides console colors for apps like RSpec and Cucumber
(Cucumber already makes use of this, and I bet it would not be too much
trouble to add to RSpec).
igem install iron-term-ansicolor
The source is available on github:
Big thanks to Danny Coates for devising a much better way to parse the
ANSI control codes!
I think I may have pushed a corrupted gem :-/ Sorry about that folks.
Trying
to get the bits in place to yank it from gemcutter and replace it with a
known good version of the gem.
This brings a question to mind - what should the general approach be for
porting existing gems to IronRuby? There could be two possible
approaches:
Create a gem with the same name (“win32console†in this case),
and specify platform==â€ironrubyâ€. That way, dependent gems do not need
to be updated, and users have to remember just one name. IronRuby will
use the version with platform==â€ironrubyâ€, and MRI will use the one with
platform==â€mswin32â€. So there should not be any clashes even if you use
MRI and IronRuby on the same machine.
Create a new gem like iron-term-ansicolor.
Any pro or cons to the two? What should the recommendation be in
general?
From: [email protected]
[mailto:[email protected]] On Behalf Of Will G.
Sent: Tuesday, March 02, 2010 7:47 AM
To: ironruby-core
Subject: Re: [Ironruby-core] iron-term-ansicolor 0.0.2 Released
I released iron-term-ansicolor 0.0.3 last night after testing the gem
install locally first.
Please let me know if you still have trouble installing it from Rubygems.org.
Also, I’ve submitted a patch to RSpec to use iron-term-ansicolor if it
can, the same way it tries to use win32console under MRI.
That all depends on how Gem checks the platform. If it uses the
RUBY_PLATFORM variable, then IronRuby needs to change what it reports
here.
Currently, it reports i386-mswin32.
I believe JRuby is doing the 1st one, which makes sense in my opinion.
If possible we should prefer platform == “ironrubyâ€, (or .net, do we
need to differentiate .net and mono?), but accept others.
This brings a question to mind - what should the general approach be for
porting existing gems to IronRuby? There could be two possible
approaches:
Create a gem with the same name (“win32console†in this case),
and specify platform==â€ironrubyâ€. That way, dependent gems do not need
to be updated, and users have to remember just one name. IronRuby will
use the version with platform==â€ironrubyâ€, and MRI will use the one with
platform==â€mswin32â€. So there should not be any clashes even if you use
MRI and IronRuby on the same machine.
Create a new gem like iron-term-ansicolor.
Any pro or cons to the two? What should the recommendation be in
general?
From: [email protected]
[mailto:[email protected]] On Behalf Of Will G.
Sent: Tuesday, March 02, 2010 7:47 AM
To: ironruby-core
Subject: Re: [Ironruby-core] iron-term-ansicolor 0.0.2 Released
I released iron-term-ansicolor 0.0.3 last night after testing the gem
install locally first.
Please let me know if you still have trouble installing it from Rubygems.org.
Also, I’ve submitted a patch to RSpec to use iron-term-ansicolor if it
can, the same way it tries to use win32console under MRI.
That all depends on how Gem checks the platform. If it uses the
RUBY_PLATFORM variable, then IronRuby needs to change what it reports
here. Currently, it reports i386-mswin32.
–
Will G.
On Tue, Mar 2, 2010 at 1:07 PM, Jim D.
<[email protected]mailto:[email protected]> wrote:
I believe JRuby is doing the 1st one, which makes sense in my opinion.
If possible we should prefer platform == “ironrubyâ€, (or .net, do we
need to differentiate .net and mono?), but accept others.
This brings a question to mind - what should the general approach be for
porting existing gems to IronRuby? There could be two possible
approaches:
Create a gem with the same name (“win32console†in this case),
and specify platform==â€ironrubyâ€. That way, dependent gems do not need
to be updated, and users have to remember just one name. IronRuby will
use the version with platform==â€ironrubyâ€, and MRI will use the one with
platform==â€mswin32â€. So there should not be any clashes even if you use
MRI and IronRuby on the same machine.
Create a new gem like iron-term-ansicolor.
Any pro or cons to the two? What should the recommendation be in
general?
With my last checkin, RbConfig::CONFIG[“archâ€] will be
“universal-.net2.0†for IronRuby. I created a gemspec as shown below.
Doing “gem build†on it will create a gem with filename of
Shri-1.2.3-universal-unknown.gem. Instead use “rbx –S gem build†and you
will get a file called Shri-1.2.3-universal-.net.gem.
I have updated with http://ironruby.net/Documentation/Real_Ruby_Applications/RubyGems with
this info:
IronRuby-specific gems
Gems could specifically target IronRuby. They may contain Ruby code
which uses .NET APIs, or they may even include compiled .NET assemblies.
In such cases, the Gem specification should set platform http://rubygems.org/read/chapter/20#platform to “universal-.net” (or
“universal-.net4.0” to run only on .NET 4), and build the gem using
IronRuby (“rbx -S gem build”).
Note that if you build the gem with MRI using “gem build”, MRI will not
be able to recognize the platform string, and will create a gem file
named something like foo-universal-unknown.gem (instead of the expected
foo-universal-.net.gem"). To avoid this, build the gem using IronRuby as
mentioned above.
Talking with Tomas, we will leave RUBY_PLATFORM set to “x86-mswin32†(on
Windows) since many apps check for “mswin32†in RUBY_PLATFORM to check
if they are running on Windows. We considered appending “.net†and
setting RUBY_PLATFORM to “.net-mswin32†or “x86-mswin32/.net†to
indicate that it was not MRI, but decided against it as you can always
check RUBY_ENGINE to detect if you are running on IronRuby.
That all depends on how Gem checks the platform. If it uses the
RUBY_PLATFORM variable, then IronRuby needs to change what it reports
here. Currently, it reports i386-mswin32.
On Tue, Mar 2, 2010 at 1:07 PM, Jim D.
<[email protected]mailto:[email protected]> wrote:
I believe JRuby is doing the 1st one, which makes sense in my opinion.
If possible we should prefer platform == “ironrubyâ€, (or .net, do we
need to differentiate .net and mono?), but accept others.
JD
From: [email protected]mailto:[email protected]
[mailto:[email protected]mailto:[email protected]]
On Behalf Of Shri B.
Sent: Tuesday, March 02, 2010 10:02 AM
To: [email protected]mailto:[email protected]
Subject: [Ironruby-core] IronRuby version of existing gems
This brings a question to mind - what should the general approach be
for porting existing gems to IronRuby? There could be two possible
approaches:
Create a gem with the same name (“win32console†in this case),
and specify platform==â€ironrubyâ€. That way, dependent gems do not need
to be updated, and users have to remember just one name. IronRuby will
use the version with platform==â€ironrubyâ€, and MRI will use the one with
platform==â€mswin32â€. So there should not be any clashes even if you use
MRI and IronRuby on the same machine.
Create a new gem like iron-term-ansicolor.
Any pro or cons to the two? What should the recommendation be in
general?