Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Comprehensive comparison between zsh and bash



On 2019-07-05 7:31 p.m., Phil Pennock wrote:
On 2019-07-05 at 13:29 -0700, Ray Andrews wrote:
Just curious:  Is there some way of dumping the state of all variables at
all lines with both bash and zsh to some file or other such that one could
quickly spot exactly when and where something might change between them?
Not a proactive, analytic study of the code, but just a pragmatic finding of
differences after the fact.
`typeset -p` dumps all variables; the format differs slightly between
shells but that's light text-munging to normalize.

This is probably a good start:

     trap 'typeset -p' DEBUG

Thanks Phil and Sebastian.  I have no need for it myself since I've never done a thing in bash, but I was wondering what might be available to converts.  I'll play with your suggestions anyway tho just for fun.  But since all the other shells are moribund it seems to me that zsh should make an effort to draw all shellers to itself and to make room around the fire for them.  It would add to critical mass and maybe spark some innovation.  Maybe there could be some purpose build conversion utilities.




Messages sorted by: Reverse Date, Date, Thread, Author