[GRASS-dev] list organization of g.list output

Glynn Clements glynn at gclements.plus.com
Thu May 24 16:54:04 EDT 2007


Paul Kelly wrote:

> >> For scripting, it would also be nice if it printed like this...
> >>
> >> aspect
> >> basin_50K
> >> boundary_county_500m
> >> cfactorbare_1m
> >> cfactorgrow_1m
> >> elev_lid792_1m
> >> elev_ned_30m
> >> elev_srtm_30m
> >> elev_state_500m
> >>
> >
> > ls changes to single column when ever stdout is not a tty.
> > That approach could be useful in the g.list case also I think.
> 
> That sounds like a good idea, although perhaps a little bit too much like 
> guessing what you want to do and doing it for you (isn't there ls -1 for 
> that?).

Multi-column listing needs to know the width of the terminal. If
stdout isn't a terminal, "the width of the terminal" isn't meaningful.

-- 
Glynn Clements <glynn at gclements.plus.com>




More information about the grass-dev mailing list