From: Greg Willits Date: 2008-10-22T15:21:03+09:00 Subject: $LOAD_PATH and different OSes Looking for best practice guidance on dealing with differing paths to libraries & gems amongst OSes. I can write some reasonably decent Ruby at this point, but still a padawan when it comes to really understanding the whole *nix ENV thing. I get that ruby has some default places it looks, and that I can manually add paths to $LOAD_PATH, but now I'm starting to develop and deploy on different OSes, and I find that my dev system finds libs and gems that my server doesn't find. I can use symlinks to force common paths, or I can put both dev and server paths into $LOAD_PATHS, but both of these methods are obviously hokey. I bet there's a better way, and I bet that somehow it involves paths in etc/profile file, but just not sure how it all goes together. Is setting path vars in profile on multiple machines really any better than setting up symlinks? It's still customizing each box (automation is my friend I know). I have at least found #!/usr/bin/env ruby to get past hard coded paths for that. dev system = OS X 10.4, servers will be 10.4, 10.5, and sometimes Cent OS variants. So, any suggestions for the Right Way™ ? -- gw -- Posted via http://www.ruby-forum.com/.