BTS

Message1137

Author ft
Recipients mika, z3ttacht
Date 2008-01-31.17:56:59
Content
Alexander Steinböck <bts@bts.grml.org>:
> Alexander Steinböck <z3ttacht@grml.org> added the comment:
> * ft <bts@bts.grml.org> [2008-01-31 10:55]:
> > check_com() checks if the command stored in $PAGER is available.
> > The latter snippet checks if $PAGER is empty and if so, sets it to
> > 'less'. My personal preference would be to use PAGER=${PAGER:-less}
> > there, because, IMHO it's a lot clearer.

> Maybe, but doesn't the current approach give $USER the ability to
> overwrite the setting?

Users are able to do a lot of things.
Overwriting this is possible, too.
It doesn't matter how it is done, check_com() should be used when it's
needed. And if I recall the place we are talking about correctly, it
*is* needed.

If it is not, you clearly failed to provide enough context, to see
what you where aiming at.

> I really can live with check_com - it's a great function - I was just
> curious how others were thinking about it. Since it came from the
> former functions with most(1) in it.

I don't see the problem at all.

> > However we should make sure that the 'export PAGER=${PAGER:-less}'
> > code is issued *before* the check_com() line.

> Isn't that down now, since the patch moved it to /etc/zsh/zshrc?

Probably, I didn't check it.

Regards, Frank

-- 
In protocol design, perfection has been reached not when there is
nothing left to add, but when there is nothing left to take away.
                                                  -- RFC 1925
History
Date User Action Args
2008-01-31 17:57:01ftsetrecipients: + z3ttacht
2008-01-31 17:57:00ftlinkissue386 messages
2008-01-31 17:56:59ftcreate