[MacRuby-devel] Documentation: appel_ref marker strings for Ruby?

2011-05-19 Thread Andrew O'Brien
Hi,

I've been looking into writing a YARD plugin that would output documentation in 
the Apple docset format. I ran into a bit of a problem when I was trying to 
setup a Tokens.xml (for API lookup) and found that there were no marker strings 
for Ruby.

According to the HeaderDoc User guide, there's C, Obj-C, Java, JavaScript, C++, 
PHP, Pascal, Perl, and Shell. It looks like docsetutil actually checks against 
this list because supplying "rb" as the lang type appeared to blow it up.

What are the chances we could get some blessed symbol types for Ruby?

Thanks,
Andrew

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


[MacRuby-devel] Rspec Stopped Running Under Macruby

2011-05-19 Thread Shannon Love
I had previously had Rspec running under Macruby before I tried to use RVM to 
manage my ruby installs. Something went awry with RVM and I had to uninstall. 
After that Rspec stopped working under Macruby. I

I found that my RVM had installed Macruby 0.11 dev in or over my 0.10 install 
and that remained even after I had removed RVM so I used pkgutil to uninstall 
all Macruby, then I reinstalled the system ruby package and then reinstall 
Macruby 0.10

The system ruby 1.8.7 runs rspec installed with its gem command just fine. 
However, if I uninstall the system rspec and install with macgem, I get the 
following error trying to either execute a file with rspec calls or running 
rspec from the command line with or without any options or files.


/Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/world.rb:14:in
 `empty_without_conditional_filters?': undefined method `empty?' for 
# (NoMethodError)
from 
/Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/world.rb:131:in
 `announce_exclusion_filter:'
from 
/Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/world.rb:103:in
 `announce_filters'
from 
/Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/command_line.rb:19:in
 `run:'
from 
/Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/runner.rb:80:in
 `run_in_process:'
from 
/Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/runner.rb:69:in
 `run:'
from 
/Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/runner.rb:11:in
 `block'
localhost:SetUpRspec developer$ which rspec


The the actual error line is here and it appears to be part of the way that 
Rspec processes command line arguments:


module RSpec
  module Core
class World

  module Describable
PROC_HEX_NUMBER = /0x[0-9a-f]+@/
PROJECT_DIR = File.expand_path('.')

def description
   reject { |k, v| RSpec::Core::Configuration::CONDITIONAL_FILTERS[k] 
== v }.inspect.gsub(PROC_HEX_NUMBER, '').gsub(PROJECT_DIR, '.').gsub(' 
(lambda)','')
end

def empty_without_conditional_filters?
14 => reject { |k, v| RSpec::Core::Configuration::CONDITIONAL_FILTERS[k] == 
v }.empty?
end

def reject
  super rescue {}
end

def empty?
  super rescue false
end
  end


I'm a ruby noob but I think it's trying to process a block returned by `super 
rescue` and it expects a collection but receives an enumerator instead. Why 
that is, I don't know.

Repeated macgem installs of the rspec gem do nothing to alter the issue.  I 
can't find any other references to similar problems. I assume that in my 
naivety with RVM and ruby in general, I wrecked something somewhere in the 
system that breaks rspec or macruby but I don't know how to fix it. 

Thanks,
TechZen
___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel


Re: [MacRuby-devel] Rspec Stopped Running Under Macruby

2011-05-19 Thread Christian Niles
Hey Shannon,

I just ran into this problem myself. I believe it has something to do with 
RSpec 2.6, since I don't get the error when rspec 2.5 is installed.

Can you try downgrading and see if that helps you as well?

christian.

On May 19, 2011, at 9:58 AM, Shannon Love wrote:

> I had previously had Rspec running under Macruby before I tried to use RVM to 
> manage my ruby installs. Something went awry with RVM and I had to uninstall. 
> After that Rspec stopped working under Macruby. I
> 
> I found that my RVM had installed Macruby 0.11 dev in or over my 0.10 install 
> and that remained even after I had removed RVM so I used pkgutil to uninstall 
> all Macruby, then I reinstalled the system ruby package and then reinstall 
> Macruby 0.10
> 
> The system ruby 1.8.7 runs rspec installed with its gem command just fine. 
> However, if I uninstall the system rspec and install with macgem, I get the 
> following error trying to either execute a file with rspec calls or running 
> rspec from the command line with or without any options or files.
> 
> 
> /Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/world.rb:14:in
>  `empty_without_conditional_filters?': undefined method `empty?' for 
> # (NoMethodError)
>   from 
> /Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/world.rb:131:in
>  `announce_exclusion_filter:'
>   from 
> /Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/world.rb:103:in
>  `announce_filters'
>   from 
> /Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/command_line.rb:19:in
>  `run:'
>   from 
> /Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/runner.rb:80:in
>  `run_in_process:'
>   from 
> /Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/runner.rb:69:in
>  `run:'
>   from 
> /Library/Frameworks/MacRuby.framework/Versions/0.10/usr/lib/ruby/Gems/1.9.2/gems/rspec-core-2.6.0/lib/rspec/core/runner.rb:11:in
>  `block'
> localhost:SetUpRspec developer$ which rspec
> 
> 
> The the actual error line is here and it appears to be part of the way that 
> Rspec processes command line arguments:
> 
> 
> module RSpec
>  module Core
>class World
> 
>  module Describable
>PROC_HEX_NUMBER = /0x[0-9a-f]+@/
>PROJECT_DIR = File.expand_path('.')
> 
>def description
>   reject { |k, v| RSpec::Core::Configuration::CONDITIONAL_FILTERS[k] 
> == v }.inspect.gsub(PROC_HEX_NUMBER, '').gsub(PROJECT_DIR, '.').gsub(' 
> (lambda)','')
>end
> 
>def empty_without_conditional_filters?
> 14 => reject { |k, v| RSpec::Core::Configuration::CONDITIONAL_FILTERS[k] 
> == v }.empty?
>end
> 
>def reject
>  super rescue {}
>end
> 
>def empty?
>  super rescue false
>end
>  end
> 
> 
> I'm a ruby noob but I think it's trying to process a block returned by `super 
> rescue` and it expects a collection but receives an enumerator instead. Why 
> that is, I don't know.
> 
> Repeated macgem installs of the rspec gem do nothing to alter the issue.  I 
> can't find any other references to similar problems. I assume that in my 
> naivety with RVM and ruby in general, I wrecked something somewhere in the 
> system that breaks rspec or macruby but I don't know how to fix it. 
> 
> Thanks,
> TechZen
> ___
> MacRuby-devel mailing list
> [email protected]
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel

___
MacRuby-devel mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel