Hmm…are you using rvm? If so, try re-running after doing a "rvm use system". Otherwise, try looking at your environment to see if any environment variables related to RubyGems are set.On Friday, November 30, 2012 at 9:09 PM, stephen horne wrote:
That reads:#!/Library/Frameworks/MacRuby.framework/Versions/0.13/usr/bin/macrubyI was using the stable 0.12 release from the macruby.org homepage. I installed a nightly to see if that helped, but it didn't.I just tried installing another macgem, the first I came across online - progressbar, and that too does not show up with macgem list local. So I wonder if there's a path issue somewhere.StephenOn 30/11/2012, at 18:54, Joshua Ballanco <jballanc@gmail.com> wrote:Try checking the shebang line on the macbacon executable:> head -1 `which macbacon`- JoshOn Friday, November 30, 2012 at 8:39 PM, stephen horne wrote:
Hi Joshua,No, I had missed that in my script, but now it's there I still get the same error. It seems to be happening in /usr/local/bin/macbacon itself, before it gets to my script.StephenOn 30/11/2012, at 18:22, Joshua Ballanco <jballanc@gmail.com> wrote:Do you have a "require 'rubygems'" in your script? Unlike Ruby 1.9, MacRuby doesn't automatically load RubyGems by default.On Friday, November 30, 2012 at 8:11 PM, stephen horne wrote:
Thanks Daniel, you were right - I'd gem installed it. I've now gem uninstalled it and tried with macgem, but whilst that claims to install it, I get a Gem::LoadError when I try to use it:$sudo macgem install mac_baconSuccessfully installed mac_bacon-1.31 gem installedand then try:$macbacon my_class_test.rbI get:/usr/local/bin/macbacon:18:in `<main>': Could not find mac_bacon (>= 0) amongst [ParseTree-2.1.1, RubyInline-3.11.3, ZenTest-4.8.2, addressable-2.2.8, autotest-4.4.6, bacon-1.1.0, bouncy-castle-java-1.5.0146.1, bundle-0.0.1, bundler-1.0.22, cheat-1.3.0, choice-0.1.6, dbi-0.4.5, debugger-1.2.2, debugger-linecache-1.1.2, debugger-ruby_core_source-1.1.5, deprecated-2.0.1, diff-lcs-1.1.3, fuzzy-string-match_pure-0.9.3, gem-man-0.3.0, git-1.2.5, hoe-3.2.0, htty-1.4.0, jruby-openssl-0.7.7, launchy-2.1.0, lolcommits-0.1.5, lucene-0.5.0.beta.1, mime-types-1.19, net-ftp-list-3.2.3, net-sftp-2.0.5, net-ssh-2.5.2, plugin_manager-1.5, rack-1.4.1, rack-test-0.6.2, rb-appscript-0.6.1, rb-fsevent-0.9.2, rbx-require-relative-0.0.9, rdebug-0.1, rdiscount-1.6.8, redcar-0.13, redcar-bundles-0.3, redcar-icons-0.3, redcar-javamateview-0.2, redcar-jruby-0.1, redcar-svnkit-0.2, rmagick-2.13.1, rspec-2.12.0, rspec-core-2.12.0, rspec-core-2.11.1, rspec-expectations-2.12.0, rspec-expectations-2.11.3, rspec-mocks-2.12.0, rspec-mocks-2.11.3, ruby-blockcache-0.2, ruby2ruby-1.1.8, sake-1.0.15, spoon-0.0.1, swt-0.13, yard-0.8.2.1] (Gem::LoadError)and indeed, when I runmacgem listthere is no mac_bacon listed there. Do you know what else I'm missing here?Thanks,StephenOn 30/11/2012, at 17:52, Daniel Westendorf <daniel@prowestech.com> wrote:Stephen,It looks like MacBacon is using MRI Ruby, not MacRuby. Did you install the gem using macgem? You might have to uninstall any other versions you've installed.I never had much luck with RVM+MacRuby; I always installed MacRuby using the installer from the website. This might have been fixed though.dw_______________________________________________On Fri, Nov 30, 2012 at 10:46 AM, stephen horne <fatste@gmail.com> wrote:I'm trying to get started with tdd and MacRuby, but I've hit a stumbling block immediately with macbacon. I suspect it's something to do with rvm, but I'm not sure.
When I run macbacon like this:$macbacon my_class_test.rbI get the following error backtrace:Can anyone see what's wrong with my setup?/Users/fatboy/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': /Users/fatboy/.rvm/gems/ruby-1.9.3-p125/gems/mac_bacon-1.3/lib/mac_bacon.rb:212: syntax error, unexpected tLABEL (SyntaxError)...eForKeyPath(key_path, ofObject:object, change:_, context:__)... ^/Users/fatboy/.rvm/gems/ruby-1.9.3-p125/gems/mac_bacon-1.3/lib/mac_bacon.rb:337: class definition in method body/Users/fatboy/.rvm/gems/ruby-1.9.3-p125/gems/mac_bacon-1.3/lib/mac_bacon.rb:429: syntax error, unexpected keyword_end, expecting $endfrom /Users/fatboy/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'from /Users/fatboy/.rvm/gems/ruby-1.9.3-p125/gems/mac_bacon-1.3/bin/macbacon:110:in `<top (required)>'from /Users/fatboy/.rvm/gems/ruby-1.9.3-p125/bin/macbacon:19:in `load'from /Users/fatboy/.rvm/gems/ruby-1.9.3-p125/bin/macbacon:19:in `<main>'Thanks.--Stephen Horne
_______________________________________________
MacRuby-devel mailing list
MacRuby-devel@lists.macosforge.org
http://lists.macosforge.org/mailman/listinfo/macruby-devel
MacRuby-devel mailing list
MacRuby-devel@lists.macosforge.org
http://lists.macosforge.org/mailman/listinfo/macruby-devel--Stephen Horne_______________________________________________MacRuby-devel mailing list_______________________________________________
MacRuby-devel mailing list
MacRuby-devel@lists.macosforge.org
http://lists.macosforge.org/mailman/listinfo/macruby-devel--Stephen Horne_______________________________________________MacRuby-devel mailing list_______________________________________________
MacRuby-devel mailing list
MacRuby-devel@lists.macosforge.org
http://lists.macosforge.org/mailman/listinfo/macruby-devel--Stephen Horne_______________________________________________MacRuby-devel mailing list_______________________________________________
MacRuby-devel mailing list
MacRuby-devel@lists.macosforge.org
http://lists.macosforge.org/mailman/listinfo/macruby-devel