2

I really like Pow, but I think I really miss an easy way to simply display the development log somehow and also interact with a binding.pry console. Isn't there an easy way to do this? I know about pry-remote, but this just is an unnecessary additional step.

Hauleth
  • 22,873
  • 4
  • 61
  • 112
Joshua Muheim
  • 12,617
  • 9
  • 76
  • 152

2 Answers2

2

The solution I use is to tail the pow logs. Tailing log/development.log is close, but does not get everything that would normally go to standard out (i.e. what you would see if you ran rails server).

On a Mac, the pow logs live in:

~/Library/Logs/Pow/apps/

To help remember this, I just add an alias:

alias kaput="tail -f ~/Library/Logs/Pow/apps/*"

This will tail the logs of all the apps together, which I like. But if you want a specific log just use the name of the app instead of the wildcard.

It's called kaput because it A) shows the things that are putsd and B) I have a kapow command that restarts pow.

csexton
  • 24,061
  • 15
  • 54
  • 57
  • This is a nice solution. However, when having `rails s`, the output is colored. Is something like this supported with `tail`? – Joshua Muheim Jan 05 '14 at 18:55
  • 1
    @JoshuaMuheim the colors are added when rails writes the output, since it is not attached to a terminal it strips the color codes. If you want to get colors in the log file it would be a matter of forcing color to be on. – csexton Jan 05 '14 at 23:32
  • Thank you. Let's see whether there arrive more answers. If not, I will accept your answer (though it's not 100% what I hoped for). – Joshua Muheim Jan 06 '14 at 07:37
1

You can use pry-remote. See FAQ in pry's wiki.

Adrien
  • 2,088
  • 1
  • 18
  • 35