Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
The Journey Fraternity
Nov 25, 2003



I found this on the ground!

Newbsylberry posted:

MailChimp looks like a good way to go! Thanks for the help.

On to the next issue, I am using devise and assigning a role to the user immediately when they sign up. I want to have a select_tag that gives the two role options 'student' and 'professional' since those are the only two roles I want people to be able to give themselves. Unfortunately devise tells me:


NoMethodError in Devise::Registrations#new

undefined method `select_tag' for #<ActionView::Helpers::FormBuilder:0x007fbbd415e608>

Here's the part of the code from the viewer that is giving me trouble:

code:
  <div><%= f.label :role %><br />
    <%= f.select_tag(:role, options_for_select('professional', 'student'))  %>
  </div>
  <br />

select_tag is its own standalone helper method- it isn't called on a form object. Drop the 'f.'

Adbot
ADBOT LOVES YOU

kayakyakr
Feb 16, 2004

Kayak is true

The Journey Fraternity posted:

select_tag is its own standalone helper method- it isn't called on a form object. Drop the 'f.'

or drop the _tag:

code:
<%= f.select :role, ['professional', 'student'] %>

Newbsylberry
Dec 29, 2007

I Swim in drag shorts because I have a SMALL PENIS

kayakyakr posted:

or drop the _tag:

code:
<%= f.select :role, ['professional', 'student'] %>

Thanks, this is what I needed!

Peristalsis
Apr 5, 2004
Move along.
I have a weird issue. I added some code into my project from another developer, and now I'm getting a missing method error in one of the files he changed (though not directly related to his changes). The code runs fine on his box, on another developer's box, and on the test server. It's only my environment having a problem with it. I should note that the same line of code that is throwing the error now, was not throwing an error on my box previously. The error refers to a method in a gem that I've had loaded for some time.

I've re-checked out the code, I've run bundle install, etc., but I'm still getting the error. My best guess is that something corrupted the gem in question on my computer. Is there a way to force rails to re-download that gem? Does anyone have any other thoughts or suggestions?

EAT THE EGGS RICOLA
May 29, 2008

Use Vagrant so that you all have the same dev environment?

Newbsylberry
Dec 29, 2007

I Swim in drag shorts because I have a SMALL PENIS
So I'm looking to host a rails4 app, and I'm not really sure what my options are. I am using heroku right now, but it's expensive and I want to use ec2, or elastic beanstalk instead. I followed the steps in this post http://stackoverflow.com/questions/15535140/installing-ruby-2-0-and-rails-4-0-0beta-on-aws-ec2 , and installed ruby and rails on an ec2 instance. I guess I'm not really sure what the next steps are, I think I have to use passenger, and/or nginx? I am having a hard time just figuring out where to start.

kayakyakr
Feb 16, 2004

Kayak is true

Newbsylberry posted:

So I'm looking to host a rails4 app, and I'm not really sure what my options are. I am using heroku right now, but it's expensive and I want to use ec2, or elastic beanstalk instead. I followed the steps in this post http://stackoverflow.com/questions/15535140/installing-ruby-2-0-and-rails-4-0-0beta-on-aws-ec2 , and installed ruby and rails on an ec2 instance. I guess I'm not really sure what the next steps are, I think I have to use passenger, and/or nginx? I am having a hard time just figuring out where to start.

if you're using elastic beanstalk, you can use their git plugin to push to ebs. It's not super flexible (ruby 1.9.3, RDS database, passenger w/ embedded nginx, limited options for DNS), but it's almost as easy as heroku: http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/create_deploy_Ruby_rails.html

For a "grown-up" deploy I would suggest learning capistrano, nginx, unicorn or thin or puma, and rvm or rbenv or whatever your preference is. You can deploy that to ec2, linode, digitalocean, or whatever your choice of virtual server is.

Newbsylberry
Dec 29, 2007

I Swim in drag shorts because I have a SMALL PENIS

kayakyakr posted:

I would suggest learning capistrano, nginx, unicorn or thin or puma, and rvm or rbenv or whatever your preference is.

Awesome, do you have a specific recommendation for one? Or is it just a preference? I use rvm now, so I'm familiar with it.

Edit - Actually I see I'll need to use a combination of them

Newbsylberry fucked around with this message at 03:11 on Oct 16, 2013

kayakyakr
Feb 16, 2004

Kayak is true

Newbsylberry posted:

Awesome, do you have a specific recommendation for one? Or is it just a preference? I use rvm now, so I'm familiar with it.

Edit - Actually I see I'll need to use a combination of them

I use capistrano, nginx, unicorn, and rvm on digital ocean.

Capistrano has plugins for unicorn and rvm and bundler that make it pretty easy to get a server going.

I'm curious about puma, but they say that it's best with jruby and since I use MRI, I've never really tried it.

Peristalsis
Apr 5, 2004
Move along.
Another weird issue.

We have

code:
class ApplicationController < ActionController::Base
  rescue_from DeviseLdapAuthenticatable::LdapException do |exception|
    render :text => exception, :status => 500
  end
  protect_from_forgery   <------
  before_filter :authenticate_user!
end
and

code:
class APIController < ApplicationController
  skip_before_filter :verify_authenticity_token  <-----
  ...
end
However, the protect_from_forgery is still being executed in the sub-class. If I comment out the protect_from_forgery line in the superclass, the subclass methods work. If I don't, they don't, despite the skip_before_filter exception. Any idea what I'm doing wrong?


Edit: This wasn't an issue until the other developer implemented logins with the devise gem. So it's possible that there's actually an issue with that, or with its interaction with LDAP or with the CSRF protection.

Peristalsis fucked around with this message at 21:29 on Oct 16, 2013

Sil
Jan 4, 2007
Gmail/spam question.

I've got a small application, sending emails 4-5 times per week to a list of 100-200 addresses(all individual emails, no CC/BCC). The list is constant, it's essentially an internal newsletter for an NGO and some of its associates.

It seemed to me like it would be the type of thing that a Gmail business account would be perfect for. Unfortunately, the one I created(but still using in trial mode) for the app just started bouncing some emails we're sending(75 from the last batch bounced with a "Message Rejected" response and a link to Google's spam policy).

Is it extra sensitive because I haven't setup payment for it yet or can Google Apps just not handle any sort of email volume? No point even bothering to pay for the Apps account if I have to use Mailchimp anyway.

waffle enthusiast
Nov 16, 2007



It's probably both. The newness of your account is a key marker for spam, as is the low volume. You should look at going through mailchimp, sendgrid, or similar. Also make sure you've setup DKIM, SPF, etc.

Sil
Jan 4, 2007

Dangerllama posted:

It's probably both. The newness of your account is a key marker for spam, as is the low volume. You should look at going through mailchimp, sendgrid, or similar. Also make sure you've setup DKIM, SPF, etc.

Hmm, I actually didn't know what DKIM or SPF were. Hopefully after I set those up the Apps account will be fine. I think the problem must be with my setup since the customer has been sending out cc/bcc emails to this list from his personal gmail account for a year with no bounce issues.

Newbsylberry
Dec 29, 2007

I Swim in drag shorts because I have a SMALL PENIS

Kayakyakr helped point me in the right direction with this: https://coderwall.com/p/yz8cha tutorial.

I am setting up the server on digital ocean, and everything is working smoothly, until this last step where you erase the default nginx sites-enabled: sudo rm /etc/nginx/sites-enabled/default .

After that I can't seem to access the IP, Domain Name, or anything else, even after I restart the Nginx server. Anyone run into this problem?

kayakyakr
Feb 16, 2004

Kayak is true
Do you have a site in sites-enabled? Is it listening to port 80? Is port 80 open in the firewall?

Pardot
Jul 25, 2001




Newbsylberry posted:

Kayakyakr helped point me in the right direction with this: https://coderwall.com/p/yz8cha tutorial.

Took a glance at this guide, it doesn't appear to have you set up WAL shipping and periodic base backups to reduce recovery time. Also be sure to use postgres 9.3 and turn on checksumming, the guide seems like it's having you install 9.1 which is now several years old. I'm not sure what the latency from digital ocean to s3 is, but if writing to s3 is fine, use wal-e.

If you're just screwing around with a hobby thing for fun, I suppose it doesn't really matter, though. Just apt installing postgres is fine then.

Sorry, this is just my periodic oh-my-god-wale-has-saved-our-asses-so-many-times post.

Newbsylberry
Dec 29, 2007

I Swim in drag shorts because I have a SMALL PENIS

kayakyakr posted:

Do you have a site in sites-enabled? Is it listening to port 80? Is port 80 open in the firewall?

I do have a site in sites-enabled, and firewall is good, when I open the site-enabled file using nano the file appears to be blank? Could this be a permissions problem?

Here is my nginx_conf file (could the problem be that my server_name is futureyoungpros.com and my site-enabled is futureyoungpros?):

code:
upstream unicorn {
  server unix:/tmp/unicorn.futureyoungpros.sock fail_timeout=0;
}

server {
  listen 80 default deferred;
  server_name futureyoungpros.com;
  root /home/cmccarthy/apps/futureyoungpros/current/public;

  location ^~ /assets/ {
    gzip_static on;
    expires max;
    add_header Cache-Control public;
  }

  try_files $uri/index.html $uri @unicorn;
  location @unicorn {
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass [url]http://unicorn;[/url]
  }

  error_page 500 502 503 504 /500.html;
  client_max_body_size 4G;
  keepalive_timeout 10;
}

Smol
Jun 1, 2011

Stat rosa pristina nomine, nomina nuda tenemus.
sites-enabled is a directory. What you want is a file inside that directory.

kayakyakr
Feb 16, 2004

Kayak is true
I would go ahead and have your server listen to all:

server_name _;

This will answer all requests which is what you want since you're not going to be hosting any other sites on there.

And that's not your nginx.conf file, right? that should be a file in sites-available named futureoungpros that's symlinked into the sites-enabled directory?

Newbsylberry
Dec 29, 2007

I Swim in drag shorts because I have a SMALL PENIS

kayakyakr posted:

I would go ahead and have your server listen to all:

server_name _;

This will answer all requests which is what you want since you're not going to be hosting any other sites on there.

And that's not your nginx.conf file, right? that should be a file in sites-available named futureoungpros that's symlinked into the sites-enabled directory?

That's my nginx.conf file on my local machine

EDIT - The sites available folder is completely empty besides the default, so there is nothing in the sites-available and an empty file in the sites-available folder

EDIT2 - Thanks to Kayakyakr for figuring out the issue I was having. I wasn't creating a sites-available file with my configuration settings in /etc/nginx/sites-available.

Newbsylberry fucked around with this message at 17:04 on Oct 22, 2013

Sil
Jan 4, 2007
loving Rails 4. Spent like 8 hours upgrading an app from 3.2.14. Premailer doesn't work, ActiveAdmin filters error the gently caress out due to my multi-select hack, god knows what other bullshit is breaking.

At least reverting back is only a 10 minute thing.

mmachine
Jan 5, 2006
Does anyone have any experience using friendly_id's history feature? I've got an app now using friendly_id already for slugs on an articles system. Unfortunately I'm having a hard time understanding the implementation of history -- I need to create a new table it seems, but then do I define the validation logic myself in my article model?

Mrs. Wynand
Nov 23, 2002

DLT 4EVA
So after spending 3 or so really quite happy years dumping Rails in favor of Python/Django, I've been pulled back in to Rails. I just wanted to vent a little:

  • God drat I miss explicit imports and file-local namespaces.
  • NO REALLY I MISS THEM SO loving MUCH
  • I see certain template errors still refuse to backtrace to the actual template. Wonderful.
  • It somehow feels even slower then it did when I left though that's probably just the fact that I'm running it from a VM in a not-too-great HP laptop instead of a (at the time) top of the line MacBook Pro. Mind you the same VM had no problems whatsoever with Python.
  • Why can't anything just have a loving normal name that describes the thing that it is/does. Gems are literally random words from the dictionary. As in, I can click Random Word in vocabulary.com, more then 1 out of 3 times it will be a ruby gem.
  • You know what's not OK? The fact that any given block just de-rigeur will redefine the local loving scope. Because we can. Here is a library for setting up a user system (named after a random dictionary word of course) - should be very straight forward right? No of course not, you have to configure it in your routes file using magic blocks that do a sort of broken poor-man's inheritance and scope passing and it's im-loving-possible to introspect what the gently caress we actually end up with and why unless we drop into the debugger. Why. Why. Why. What possible productivity saving do we achieve that is worth so many layers of indirection and action-at-a-distance and what-you-see-is-not-what-you-get.

I used to really really like Rails - before my Django defection I had (I think) 4-5 years working with it. But coming back to it now feels like running into a high school acquaintance that failed to grow up at all for the last 20 years and it's just sad and depressing. Maybe I'm just becoming a crusty old neckbeard but I seem to be loosing my tolerance for these juvenile little hipster software projects where everything has to be cool and meta and we are far more concerned with writing executable code poems than such pedestrian concerns as consistency and clarity. Node.js I'm looking at you too here, jesus christ, talk about something with absolutely no redeeming qualities.

Ok, like I said, just venting. Yeah yeah, some people write reasonable ruby, yeah yeah language isn't as important as how you actually use it, yeah yeah, why don't I just go back to python if I love it so much. It's fine, I'll be fine, I'm just not happy about it is all.

Smol
Jun 1, 2011

Stat rosa pristina nomine, nomina nuda tenemus.
I haven't seen any libraries instance_evaling a block in a while. What library is doing that evil trick? It used to be somewhat popular in the past, but I guess most people realized that it's just a bad idea.

Mrs. Wynand
Nov 23, 2002

DLT 4EVA

Smol posted:

I haven't seen any libraries instance_evaling a block in a while. What library is doing that evil trick? It used to be somewhat popular in the past, but I guess most people realized that it's just a bad idea.

devise is doing something weird with block_scope.

And yeah I definitely see people backing away from that mindset, I guess I was just sort of hoping it would have died by now :(

no_funeral
Jul 4, 2004

why
I'm having trouble getting my poo poo working! What I'm trying to do is have a comment box appear via ajax in a comment thread(which works for users who are signed in) after somebody signs up/logs in via facebook(which also works), using the facebook javascript sdk. What isn't working is whats happening in between. The way its set up is in the user authorization controller's create method, I do a check for the request format(json for the in-thread sign up/login, and text/html for when it's called from the actual sign up/login page), and depending on which it is I either do a redirect for the html call, or a respond_to with a success code for the ajax call, which is then checked in the javascript function. The javascript function is then supposed to call the function which displays the comment box. When I call it via a comment thread it displays the sign up with facebook popup, and after entering my facebook credentials it just does the login, but doesn't display the reply box(once I do a full pageload, I'm logged in via facebook.) The function being called to display the comment box is bound to the window, and when I check in the dev console the window does have access to it.

My question: does anybody have any ideas for how to debug this? I'm using RubyMine to debug the ruby code, and the chrome dev console to debug the javascript, so its a bit hairy trying to combine the two. The javascript function which sends out the facebook login request and subsequently checks for the success code from the authorization create method is doing both of those things correctly, and definitely has access to the function for displaying the reply box, but I can't think of a good way to figure out where the son of bitch is dying.

I know this is pretty vague, but I hope somebody will be able to at least point me in the right direction.

Jam2
Jan 15, 2008

With Energy For Mayhem
Gripe:

When I develop object-oriented backend systems in a framework-agnostic manner, I am able to decouple objects and generally decompose problems in a sensible, maintainable way.

However, whenever I write rails apps, database persistence usurps all other considerations and invariably winds up dictating the structure of the system. The Rails Way always seems to result in a flat collection of strongly-connected models.

It's never pretty and it's often not the way I would model the system if I didn't have to map it to a database schema. Things would often look very different if objects weren't mapped to a schema.

Have you seen any examples of rails applications that are cleanly decomposed and don't seem like spaghetti balls of strongly-connected models?

Cocoa Crispies
Jul 20, 2001

Vehicular Manslaughter!

Pillbug

Jam2 posted:

Have you seen any examples of rails applications that are cleanly decomposed and don't seem like spaghetti balls of strongly-connected models?

I don't have any examples in public code, but there's nothing stopping you from decoupling stuff into non-persisted classes. I'd say that except for trivial cases, it's more idiomatic to do so than to just try and jam a whole family of methods on to a model that it might not quite fit on.

Molten Llama
Sep 20, 2006

Jam2 posted:

It's never pretty and it's often not the way I would model the system if I didn't have to map it to a database schema. Things would often look very different if objects weren't mapped to a schema.

Data you want to persist is mapped to a database schema, not particularly differently from any other serialization strategy. Though whole objects worth of data are frequently persisted, you don't have to persist all or even any of an object's data.

I'm not trying to be an rear end—this is a conceptual issue I frequently encounter in the wild—but you do realize model classes are just Ruby classes, right? They can (and frequently should) do more than be a thin veneer over ActiveRecord/Mongoid/DataMapper/whatever. Rails doesn't care what else you make that class do. ActiveModel and the mappers implementing it don't care what that class does. Rails doesn't even care if models use a particular mapper (or any mapper) or are persisted at all; if it's in the models directory and it's Ruby code, it's loaded.

Notably, Rails 4 natively autoloads service object classes from a services directory. The modern Rails Way is decomposition and coupling as loose as you can get it.

Molten Llama fucked around with this message at 16:58 on Nov 6, 2013

kayakyakr
Feb 16, 2004

Kayak is true

Molten Llama posted:

Data you want to persist is mapped to a database schema, not particularly differently from any other serialization strategy. Though whole objects worth of data are frequently persisted, you don't have to persist all or even any of an object's data.

I'm not trying to be an rear end—this is a conceptual issue I frequently encounter in the wild—but you do realize model classes are just Ruby classes, right? They can (and frequently should) do more than be a thin veneer over ActiveRecord/Mongoid/DataMapper/whatever. Rails doesn't care what else you make that class do. ActiveModel and the mappers implementing it don't care what that class does. Rails doesn't even care if models use a particular mapper (or any mapper) or are persisted at all; if it's in the models directory and it's Ruby code, it's loaded.

Notably, Rails 4 natively autoloads service object classes from a services directory. The modern Rails Way is decomposition and coupling as loose as you can get it.

Good post. Rails is as flexible as you want it to be. Most rails apps people come up with are just front ends to a database schema and so they wind up reflecting the database. This should be a surprise to absolutely no one and I've seen the same setup used in languages and setups that aren't rails written with a lot more code.

Database-wise, ActiveRecord does encourage a pretty decent bit of normalization, and as a SQL guy, I approve of that direction heartily.

Jam2
Jan 15, 2008

With Energy For Mayhem

Molten Llama posted:


Notably, Rails 4 natively autoloads service object classes from a services directory. The modern Rails Way is decomposition and coupling as loose as you can get it.

Thanks for the great reply. Do you recommend any resources for learning how experienced rails users model their backends to achieve what you describe?

Or is it simply trial and error and experience?

Peristalsis
Apr 5, 2004
Move along.
We have a shiny new RoR app with a web interface and a webserivce API for backend access. I want to adapt an old Ruby script (no Rails) to use that API, but it'll be a lot easier if I can use some of the model classes from the web app to do some parsing and processing.

This is a completely different app, running in a different directory (probably even on a different server). Is there a good way to import some of my ActiveRecord models from the Rails app to use in plain Ruby? I really don't want to re-write all the necessary logic.

kayakyakr
Feb 16, 2004

Kayak is true

Peristalsis posted:

We have a shiny new RoR app with a web interface and a webserivce API for backend access. I want to adapt an old Ruby script (no Rails) to use that API, but it'll be a lot easier if I can use some of the model classes from the web app to do some parsing and processing.

This is a completely different app, running in a different directory (probably even on a different server). Is there a good way to import some of my ActiveRecord models from the Rails app to use in plain Ruby? I really don't want to re-write all the necessary logic.

You can create a gem with those models extracted out. You'll have to require all the necessaries in order to set up ActiveRecord, the database connections, etc for the non-rails app, but it'd be doable.

KoRMaK
Jul 31, 2012



In Ruby, I have a ASCII-8bit stream that contains a xls workbook. I want to open the workbook via the Workbook gem, but it requires a file. Is there a way I can read the stream into a file object without actually writing it to disk? This link seems close to what I am trying http://stackoverflow.com/questions/5931263/memory-streams-in-ruby

e: I tried it and it almost works. The Workbook gem tries to do a rewind on it, and I get an "Illegal Seek" error.

https://github.com/zdavatz/spreadsheet/blob/master/lib/spreadsheet/excel/reader.rb#L1198

KoRMaK fucked around with this message at 21:02 on Nov 8, 2013

The Journey Fraternity
Nov 25, 2003



I found this on the ground!

KoRMaK posted:

In Ruby, I have a ASCII-8bit stream that contains a xls workbook. I want to open the workbook via the Workbook gem, but it requires a file. Is there a way I can read the stream into a file object without actually writing it to disk? This link seems close to what I am trying http://stackoverflow.com/questions/5931263/memory-streams-in-ruby

e: I tried it and it almost works. The Workbook gem tries to do a rewind on it, and I get an "Illegal Seek" error.

https://github.com/zdavatz/spreadsheet/blob/master/lib/spreadsheet/excel/reader.rb#L1198

You could try wrapping it in a delegator that declares rewind as a noop.

Soup in a Bag
Dec 4, 2009
If you want to read the entire stream in and then use it as if it were a file, check out StringIO. It responds to #rewind and all the other File/IO-ish methods.

prom candy
Dec 16, 2005

Only I may dance

Jam2 posted:

Thanks for the great reply. Do you recommend any resources for learning how experienced rails users model their backends to achieve what you describe?

Or is it simply trial and error and experience?

You want to read the book Objects on Rails, which is free online. You also probably want to watch some of the Destroy All Software screencasts, which are not free but are worth the money. Russ Olsen's book "Design Patterns in Ruby" is also a good read.

"Skinny controller fat model" was a really popular concept a few years ago and really set Rails back a bit since everyone would just jam everything into the model. I inherited a project that has a 1000-line model. My opinion is that if it's not directly related to getting and storing objects in the database it belongs elsewhere.

Fillerbunny
Jul 25, 2002

so confused.
Hey guys,

Routes in Rails have long confused the poo poo out of me, and I'm now working in my first Rails 4 app. I have some experience in Rails 3, though I'm currently strongest writing pure Ruby.

Regardless, this app I'm writing maintains a list of applications. To reduce potential internal Rails Deep Logic naming collisions, I'm referring to the controller and model for this element as one thing internally but want the URLs to read to the user as something else.

Because I think an example will help illustrate, let's say I have a model called MyApp, the controller for that as MyAppsController, and I want the user to be able to access that resource through http://address.what/apps.

Right now, in my Routes.rb file I've got:

Ruby code:
resources :apps, controller: :my_apps
Which does more or less what I'm looking for, but it breaks all sorts of convention regarding generated paths. Anybody got any tips for this sort of thing? Do I need to just suck it up and read and comprehend this whole thing?

edit: I worked this out, mostly. I did my best to comprehend that routes guide. I needed to add :as to my route, like so:
Ruby code:
resources :apps, controller: :my_apps, as: :my_apps
Now I'm having issues with pluralization. Back to the routing guide. :sigh:

Fillerbunny fucked around with this message at 21:20 on Nov 10, 2013

KoRMaK
Jul 31, 2012



Soup in a Bag posted:

If you want to read the entire stream in and then use it as if it were a file, check out StringIO. It responds to #rewind and all the other File/IO-ish methods.
I will try that. Thank you.

Now I have a public staging/development area and a production are on heroku. Heroku offers a nice easy way to manage which app you are managing. I needed to get my DB up and it just requires adding -app APPNAME at the end of the commands.

I have another problem with an app I've already deployed to heroku that I am creating a new instance of and for some reason it fails at the assets:precompile step. Here's the push log I get

code:
rake aborted!
Invalid CSS after "  padding": expected ";", was ": 10px;"
  (in /media/sf_clunker/app/assets/stylesheets/application.css)
(sass):5655

So somehwere in sass.css or sass.css.sass or whatever there is some invalid css. However, I don't have access to that file, it's part of the sass-rails gem. I'm not sure where to go next to fix it.

e: Fixed! There was a comma where a semi-colon should have been in bootstrap.css.

When I run rake assets:precompile locally I get this

quote:

Text file busy - (/media/sf_clunker/tmp/cache/sass/1764c37ed8cf48e1638694abf11caad17c086877/gritter.css.scssc20131110-2125-a7ip2g, /media/sf_clunker/tmp/cache/sass/1764c37ed8cf48e1638694abf11caad17c086877/gritter.css.scssc)

Text file busy? :confused:

KoRMaK fucked around with this message at 05:41 on Nov 11, 2013

Adbot
ADBOT LOVES YOU

Jam2
Jan 15, 2008

With Energy For Mayhem

prom candy posted:

You want to read the book Objects on Rails, which is free online. You also probably want to watch some of the Destroy All Software screencasts, which are not free but are worth the money. Russ Olsen's book "Design Patterns in Ruby" is also a good read.

"Skinny controller fat model" was a really popular concept a few years ago and really set Rails back a bit since everyone would just jam everything into the model. I inherited a project that has a 1000-line model. My opinion is that if it's not directly related to getting and storing objects in the database it belongs elsewhere.

Fantastic recommendations. Thank you very much. I'm only 10 pages in, and Objects on Rails is already moving me forward.

Objects on Rails is a spiritual experience. Thank you based god.

Jam2 fucked around with this message at 06:45 on Nov 12, 2013

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply