librelist archives

« back to archive

Quick dumb question re rails gem

Quick dumb question re rails gem

From:
Jake Subs
Date:
2012-02-10 @ 16:41
Just a quick question, are rails gems generally compatible with Sinatra/Nesta?

Someone's packaged up Tyler Tate's semantic.gs Sass responsive grid,
and I wondered if this would work without any messing:
https://github.com/bokmann/semanticgs-rails/blob/master/README.md

tia, Jake

Re: [nesta] Quick dumb question re rails gem

From:
Graham Ashton
Date:
2012-02-10 @ 18:43
On 10 Feb 2012, at 16:41, Jake Subs wrote:

> Just a quick question, are rails gems generally compatible with Sinatra/Nesta?

Gems that contain Ruby code are sometimes usable in any Ruby project. Gems
that contain Ruby code that use Rails's API to work won't be compatible. 
So it depends really.

> Someone's packaged up Tyler Tate's semantic.gs Sass responsive grid,
> and I wondered if this would work without any messing:
> https://github.com/bokmann/semanticgs-rails/blob/master/README.md


I had a look at the gem, and all it does is copy grid.scss [1] into the 
user's Rails project. It drops it into a location that gets automatically 
picked up by Rails itself; that's the only reason that it's a "rails gem" 
as such.

Personally I think making gems for distributing single CSS files is a bit 
over the top, but I suspect it's a pattern that we'll be seeing more of in
future. :-(

To use grid.scss in Nesta just drop grid.scss in your views folder and 
you'll be good to go.

[1] 
https://github.com/bokmann/semanticgs-rails/blob/master/vendor/assets/stylesheets/grid.scss

-- 
Graham Ashton
Founder, The Agile Planner
http://theagileplanner.com | @agileplanner | @grahamashton




Re: [nesta] Quick dumb question re rails gem

From:
Jake Subs
Date:
2012-02-11 @ 13:01
On 10 February 2012 18:43, Graham Ashton <graham@effectif.com> wrote:
>> Just a quick question, are rails gems generally compatible with Sinatra/Nesta?
> Gems that contain Ruby code are sometimes usable in any Ruby project. 
Gems that contain Ruby code that use Rails's API to work won't be 
compatible.

Thanks for the info

>> Someone's packaged up Tyler Tate's semantic.gs Sass responsive grid,
>> and I wondered if this would work without any messing:
>> https://github.com/bokmann/semanticgs-rails/blob/master/README.md
> I had a look at the gem, and all it does is copy grid.scss [1] into the 
user's Rails project.

Didn't realise that was all it did!

> Personally I think making gems for distributing single CSS files is a 
bit over the top, but I suspect it's a pattern that we'll be seeing more 
of in future. :-(
> To use grid.scss in Nesta just drop grid.scss in your views folder and 
you'll be good to go.

That is really over the top, more bother than it's worth.

Thanks for  your help :)

Re: [nesta] Quick dumb question re rails gem

From:
Graham Ashton
Date:
2012-02-11 @ 13:46
On 11 Feb 2012, at 13:01, Jake Subs <subs@growdigital.org> wrote:

> That is really over the top, more bother than it's worth.

Wynn pointed out that the gem contains an scss file, while the original 
was plain CSS. So perhaps there's more of an argument for it in this case.
It doesn't feel quite right to me though...