rerun
rerun copied to clipboard
Monitor ../directory
I've got a projects folder with a layout like: Projects/ ─ rails_admin/ ─ api-project/
My api-project directory contains a standard rails project, and rails_admin is a fork of the rails_admin gem that I work on locally, and that I include via path sometimes in my Gemfile.
I think it'd be really cool if I could essentially do:
bundle exec rerun --background --dir app,lib --dir ../rails_admin/app --dir ../rails_admin/lib -- bundle exec rails s -p 3002 -P tmp/pids/admin.pid -e development_admin
... while inside the api-project folder, so that whenever I make changes to my local copy of the rails_admin gem, my rails server gets restarted.
I attempted to do this by starting my server via rerun with the above command, but it doesn't seem to be working in the way I'd hope it might, i.e., if I edit a file within the rails_admin directory that it ought to restart the server. I'm not sure why this wouldn't work, and I assume I'm running into a fairly rare and unintended use-case. But I guess it doesn't hurt to ask– is there any obvious thing I might simply be doing wrong or missing? I'm not very familiar with how this filesystem monitoring stuff works, but I'd be glad to try to help implement this feature if there's not perhaps some obvious reason why it's technically unfeasible.
Thanks!