Skip to content

Instantly share code, notes, and snippets.

@demisx
Last active December 31, 2020 07:48
Show Gist options
  • Star 9 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save demisx/10341686 to your computer and use it in GitHub Desktop.
Save demisx/10341686 to your computer and use it in GitHub Desktop.
Regenerate and Springify Rails 4 binstubs
cd my_rails_app_root_dir
rm bin/*
bundle exec rake rails:update:bin
bundle binstubs rspec-core
spring binstub --all
@lucianosousa
Copy link

rails 5.x
bundle exec rake app:update:bin

@jsimpson
Copy link

jsimpson commented Mar 7, 2018

Good grief. Thanks for this! My binstubs were inexplicably jacked up by a co-workers recent commit and it took me quite a while to realize it was the binstubs that were bad and an even longer time to sort out how to update them in Rails 5.1.x.

@JoshCheek
Copy link

Update: it's apparently now bundle exec rake app:updates:bin, and also note that you need the gem spring-commands-rspec

@scarroll32
Copy link

scarroll32 commented Nov 1, 2019

Update: it's apparently now bundle exec rake app:updates:bin, and also note that you need the gem spring-commands-rspec

Should be bundle exec rake app:update:bin

It's also helpful to add Webpacker binstubs

rails webpacker:binstubs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment