shoes / shoes-deprecated

Former repo for Shoes... see README for up to date locations!
http://shoesrb.com/
Other
1.15k stars 168 forks source link

Using gems with Shoes #237

Closed SankarMS closed 11 years ago

SankarMS commented 11 years ago

I'm trying to build a simple shoes application using the httparty gem. I have ruby installed in C:\Ruby200-x64 and Shoes 3 installed on my Windows 8 machine. I opened a cmd window and navigated to C:\Ruby200-x64 and did gem install httparty and it installed everything. At the top of my shoes code I have

Shoes.setup do
  gem 'httparty'
end

require 'httparty'

Shoes.app do
...
end

But then everytime I run shoes and open up the .rb file, it says Error while installing httparty. WHERE exactly am I supposed to put this gem file? Or how can I tell shoes to look in the ruby directory?

steveklabnik commented 11 years ago

Shoes embeds its own Ruby, so 'gem install httppartywon't get it in your Shoes. Depending on which JSON/XML libraryhttpparty` chooses, it has a C extension, so it won't work with Shoes unless you build a custom one.

I suggest you try out Shoes 4 (shoes/shoes4) or Green Shoes (ashbb/green_shoes) instead, they're being worked on instead of shoes/shoes for exactly this reason.