react_on_rails icon indicating copy to clipboard operation
react_on_rails copied to clipboard

Install script should create `./bin/dev`

Open jasonfb opened this issue 2 years ago • 1 comments

  • [ ] For parity with JSBundling, the installer script should create a simple shell script at ./bin/dev with this contents:
#!/usr/bin/env bash
if ! command -v foreman &> /dev/null
then
  echo "Installing foreman…"
  gem install foreman
fi
foreman start -f Procfile.dev-static
  • [ ] remember shell script must be set to be executable (chmod 0755 ./bin/dev)

  • [ ] use the post-install message to direct people to this option

TODO: @jasonfb says he will PR this.

jasonfb avatar Sep 21 '22 15:09 jasonfb

the only purpose of this is to standardize the development process across different paradigms (Importmap, JSBundling, Webpacker, Shakapacker, etc) so that new devs don't have to learn a different way to boot their Rails app for each new app they work on. (I realize that the exception is still default Rails installation with Importmaps which has no ./bin/dev tool)

jasonfb avatar Sep 21 '22 15:09 jasonfb

@jasonfb I like the idea. Can you throw in a PR?

justin808 avatar Oct 26 '22 08:10 justin808

@jasonfb I like the idea. Can you throw in a PR?

Keep me as backup

ahangarha avatar Oct 26 '22 08:10 ahangarha

@ahangarha you can do this if you like. It's simple enough.

justin808 avatar Oct 26 '22 08:10 justin808