From: Henryk M. <hmo...@eo...> - 2008-02-21 23:26:02
|
I know at least a couple of people who would subscribe to this idea with both hands. This feature is more nuisance than help. A very easy solution with minimal programming effort would be to spill out the documentation only when a user explicitly requests it like: 1. in Madagascar syntax sfcommand help=y 2. or in more Unix-like way with sfcommand -h/--help Or, even easier, entirely rely on sfdoc to do that. Producing man pages is a relatively large effort. After all it is just a difference in a way how one asks for help. Henryk _______________________________________________________ Henryk Modzelewski, UBC EOS, SLIM/WFRT Contact info: http://www.eos.ubc.ca/~henryk/ "For what are we left with if there remains no mystery? What hope might we find if we know all of the answers?" Drizzt Do'Urden _______________________________________________________ On Feb 21, 2008, at 2:40 AM, i....@ya... wrote: > One of the reasons why I am tinkering with Madagascar (m8r) is to > better understand programming systems architecture, so I always > tend to come up with the question "why was this done this way?" So, > please do not mind if I ask, in this case, why was the standard > Unix solution of having man pages not used? > > Some programs work well with just the defaults and no arguments, > and some very simple ones do not even need to have any arguments at > all (Especially rsflib function wrappers that are needed if one > wants to perform certain operation directly from SCons or other > Python metaprograms). On top of that, the documentation is sent to > stdout as legitimate output, instead of stderr, so running "<in.rsf > sfsomething > out.rsf" does not give an error, but produces an > out.rsf containing... documentation. > > Trying to answer my own question, I would guess that possible > answers include: (1) awkward syntax of official ways of creating > man pages; (2) Official location of man pages (/usr/share/man) is > not write-able by users; (3) Backwards compatibility with other > packages. > > Analyzing them, at (1) one could say that since rsfdoc exists > anyway, it should be possible to output troff syntax for man pages; > at (2) -- can be solved for an userspace install by adding "export > MANPATH=$MANPATH:$RSFROOT/share/man" to the environment setup > during initial install; at (3) -- most backwards compatibility in > m8r seems to be with SEPlib, but I distinctly recall using SEPlib > programs such as Window and Tpow with no arguments. > > So... why? > > Thank you, > Nick > > > ----- Original Message ---- > From: Sergey Fomel <ser...@gm...> > To: Darren Foltinek <dar...@ac...> > Cc: rsf...@li... > Sent: Wednesday, February 20, 2008 10:27:26 PM > Subject: Re: [rsf-user] Help with Python API > > Darren, > > A simple solution is to give your script an argument when you run it: > > ./simple.py test > > instead of > > ./simple.py > > "Magagascar" programs are conditioned to display self-documentation > when run without arguments or input. However, self-documentation only > works if a program is included in the RSF installation. > > SF > > On Wed, Feb 20, 2008 at 12:37 PM, Darren Foltinek > <dar...@ac...> wrote: > >> This code, in an executable Unix file called "simple.py" produces the >> following output when run: >> >> >> >> "No program sfsimple.py in RSF." > > ---------------------------------------------------------------------- > --- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > RSF-user mailing list > RSF...@li... > https://lists.sourceforge.net/lists/listinfo/rsf-user > > ---------------------------------------------------------------------- > --- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > RSF-user mailing list > RSF...@li... > https://lists.sourceforge.net/lists/listinfo/rsf-user |