Best is if you fork the project on GitHub and then send me a pull request from your topic branch. That allows me to merge in your work in a very streamlined fashion. Second best is to attach the patch files to your message to this group. Tom
On Wed, Nov 19, 2008 at 7:28 AM, Ben Taitelbaum <[EMAIL PROTECTED]> wrote: > > > I've uploaded a simple patch that keeps the current working directory. > Sorry, I uploaded it twice - the first is just a diff, and the second > (the 0001... file) is the proper git-format-patch way. > > It'd be nice to have a way of specifying if this is the desired > behavior (like Watch#pwd), and I'm not sure if this has unintended > consequences for some daemons, but it solves my problems at least. > > Is this the best place (in the Files section) to submit a patch? > > Thanks, > Ben > > On Nov 18, 4:04 pm, Ben Taitelbaum <[EMAIL PROTECTED]> wrote: > > I have a watch that I let god daemonize (I don't specify the pid > > directory). It works very well, except the process has a few places > > where it opens files using relative paths, so I'd like the process to > > have the same working directory as wherever the user starts god from. > > I've tried setting ENV['PWD'] as well as watch.env['PWD'], and these > > pass the environment variable to the daemonized process, but inside > > the process, running `pwd` fails. > > > > I tried patching process.rb with something like: > > <code>Dir.chdir(ENV['PWD']) if ENV['pwd']</code> > > inside spawn, in the loop where it copies env to ENV, but `pwd` in the > > spawned process still reports '/' (which isn't what `pwd` in the god > > process reports). > > > -- Tom Preston-Werner github.com/mojombo --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "god.rb" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/god-rb?hl=en -~----------~----~----~----~------~----~------~--~---
