rinari icon indicating copy to clipboard operation
rinari copied to clipboard

Zeus support

Open asok opened this issue 12 years ago • 5 comments

It would be nice if rinari could support zeus for running scripts and console. Actually it should be easy. You just check if the .zeus.sock file exists in the rails directory. I commited something like this to rails-mode. If you want I can write something similar to rinari.

asok avatar Nov 08 '12 11:11 asok

Interesting. It looks like:

  • zeus discourages the bundle exec zeus style
  • zeus commands need to be specified in zeus.json
  • zeus needs to be started before running the commands

I'm concerned that it would be harder than you expect to integrate zeus with rinari in a robust way, but I'm happy to consider a patch, so by all means have a look through rinari.el and ruby-compilation and see what you can come up with! :-)

purcell avatar Nov 08 '12 12:11 purcell

I was thinking of something basic:

  • User have setup Zeus (that is ran zeus init in the project root)
  • User starts Zeus in the console with zeus start, by now file .zues.sock is created in the root project
  • emacs checks if file .zeus.sock exists, if yes it runs zeus server instead of rails server, zeus console instead of rails console and so on

asok avatar Nov 08 '12 18:11 asok

Hey, so I took a look through the code, and it's easy to intercept where "server", "console" and "generate" are run from rinari.el. However, "rake" goes through ruby-compilation.el, and in fact all of the commands eventually call ruby-compilation-do, so that's where the hacking would have to start.

It's a bit fiddly, though, and I'm out of time right now, but I'll come back to this because now I'm also interested in getting it working. :-)

purcell avatar Nov 08 '12 21:11 purcell

I should also note (partly for my own benefit) that there is likely to be some confusing behaviour, since rinari allows the user to run, say, "rails console production", but "zeus console" ignores any additional arguments and just runs the command in the development environment.

purcell avatar Nov 09 '12 11:11 purcell

I would love to assist with Zeus support.

localredhead avatar May 30 '13 08:05 localredhead