I have a Ruby app which (on Linux) uses the /proc filesystem to get information on its memory usage. Does anyone know how to get the same information for Mac OSX? The task_info
Referring to this answer it seems like you need to call proc_pidinfo(). I don't think there's a Ruby equivalent, so either you'll have to write a C-extension or use the ruby-ffi gem.
Other sources indicate Ruby 1.9.2 ships with a built in FFI -- but that version is not delivered with OS X.