From: transfire@... Date: 2006-06-20T01:53:40+09:00 Subject: Re: best way to deal with command line options thomas coopman wrote: > Hi, > > I'm verry new to ruby, just use it for some days now and I have question about the best implementation of how to deal with command line options. > > Suppose I have a program, with a class say A and a main. > My program also has a verbose option (program --verbose). > What's the best way to implement the verbose option in a OO-way? These kind of options are often best implemented via global vars. eg. $VERBOSE. That might seems anti OOP but the reason is that if your program gets big --ie. spreads across multiple classes, passing such "universally applicable" options around gets old real qucik. T.