RailsCasts Pro episodes are now free!
Learn more or hide this
GitHub User: murdoch
Can you tell us what an alternative would be?
Yeah, you should find the following at the bottom of your spec/spec_helper.rb file:
# Run specs in random order to surface order dependencies.
config.order = "random"
This has been part of rspec for several months now, you probs just didn't notice it.
Watch the Client Side Validations railscast: http://railscasts.com/episodes/263-client-side-validations
This is a known bug with webrick, you can ignore it, or use a different server, more here on stackoverflow: http://stackoverflow.com/questions/9612618/warn-could-not-determine-content-length-of-response-body-set-content-length-of
thanks for that link, some excellent tips from that guy
Lets say I had an app on heroku, with omniauth configured to let users sign in with twitter. Would I need an SSL certificate on my site, or is it safe without one?
If you are on linux or mac, then you can put it a file called /home/.bashrc
Tip: Use your real variable name, there's usually no need for quotation marks, and the export keyword is required as shown above. Finally, you should make sure your variable name is written in UPPER_CASE.
Remember to save and close the file, before reloading your command prompt.
Quick question, I notice that the facebook sign-in popup uses SSL, but the app you create does not. Would you recommend adding SSL everywhere, in order to stop session attacks? Heroku charge a whopping $20 per month to enable SSL endpoints.
ditto, and there have been some damn good episodes over the years
This github issue might help you fix the problem, it looks like you want to substitute all references to activerecord with activemodel. Make sure you do it in your locale file too.
Chapter 8 of railstutorial shows you how to do that: http://ruby.railstutorial.org/chapters/sign-in-sign-out#top
Pay particular attention to section: 8.2.1 titled "Remember me"
what Operating System are you using?
"bundler will only fetch the metadata for the gems that it needs, and not every gem known to man"
made me laugh :)
creating contact pages used to be a bit of a pain, but this makes life much easier
been using this for a while myself, along with flutie, also by thoughtbot
thanks ryan, fwiw, here's decent tutorial on how to get bootstrap-sass, formtastic and tabulous working together: http://rubysource.com/too-good-to-be-true-twitter-bootstrap-meets-formtastic-and-tabulous/
Thanks so much for this one. There's also a decent tutorial on heroku's website that shows you how to build a static site using rack - link here http://devcenter.heroku.com/articles/static-sites-on-heroku
thankyou, I've actually been using this gem since the early days of development but did not know about History module until today. It's a neat feature.
I have a question regarding the history module.
Let's say that I create a post titled "Hello" and get the url site.com/post/hello but I decide to update the title to "Hello World" and I now have an updated URL site.com/post/hello-world.
I use the history module to redirect from the old url to the updated one.
What happens if I try to create a new post with the old title? (Imagine that I have validates :title, :uniqueness=> true)
validates :title, :uniqueness=> true
Will ActiveRecord take friendly_id's historic slugs into consideration when validating future user inputs?
yes, and it's also definitely worth checking out Ruby Monk as well as The Ruby Game
Totally blown away by this. It makes AJAX so much easier, the way it should be, thank you
My features are running twice too. Is that normal? I understand that two spork environments are requires, but surely my features should only run once?
I find myself getting the following error unless I include guard in my Gemfile too:
No such file or directory - Guardfile (Errno::ENOENT)
FWIW, using rails 3.1.1 and guard-rspec 0.5.0
Just saying incase anyone else runs into this problem too
really like the coffee script stuff in this, I learned a lot
that's pretty much the way a lot of people are doing things now - although I dunno if authentication is something for which I'd use an engine - maybe you would though
if you can afford it, I'd recommend buying and reading "Crafting Rails Applications" by Jose Valim, from where much of rails3.1's updated engine code was extracted (see the enginex gem if you're on older rails)
ryan bigg posted a link to this nice forum engine he made http://github.com/radar/forem
and here's my favourite engine atm (called rails admin) which handles all your back-end stuff (== no more django-envy): https://github.com/sferik/rails_admin
great new site Ryan
you read my mind with this railscast - was looking for something like this
nice work, like it