[issue2194] [PATCH] zrcautoload() improved and ZSHified

Thilo Six bts at bts.grml.org
Sun May 8 15:26:32 CEST 2016


New submission from Thilo Six <grml at xk2c.de>:

Hello hopefully-not-so-grml-today folks,   ;)

i was looking at zrcautoload() and the various cases where it would be used.
When i came down to where run-help is initialised i thought it would be better
to not hardcode functions names and was looking for a general solution for that.
After having found that in the fine manual (actually several hours later....) it
occured that zrcautoload() itself could be improved.
And so here you go:

chnagelog:
* MOD: zrcautoload()
       * make it multi argument aware
         returns 0 when all PARAMETERS had been autoloaded
         returns 1 when at least one PARAMETER could not be found for autoloading
         returns 2 when autoload itself had some problem
       * ZSHified, i.e. use globbing instead of looping
* MOD: with the modified zrcautoload() from above a few use cases could be optimized
* FIX: zrcautozle() drop superflous variable 'fnc'
* FIX: run-help, do not hardcode function names, there were allready some missing
       instead use what is avail on system

As usual i tried hard not to introduce regressions.
Actually i left some debuiing echos in the code.
This should make it easier for you to review and in case to trace down a problem.

kind regards,

Thilo

----------
files: 0001-PATCH-zrcautoload-improved-and-ZSHified.patch
messages: 5859
nosy: Xk2c
priority: bug
status: unread
title: [PATCH] zrcautoload() improved and ZSHified

_____________________________________
GRML issue tracker <bts at bts.grml.org>
<http://bts.grml.org/grml/issue2194>
_____________________________________
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-PATCH-zrcautoload-improved-and-ZSHified.patch
Type: text/x-diff
Size: 4104 bytes
Desc: not available
URL: <http://ml.grml.org/pipermail/bugs-changes/attachments/20160508/ed6001cf/attachment.patch>


More information about the Bugs-changes mailing list