Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm
Precedence: bulk
X-No-Archive: yes
List-Id: Zsh Workers List <zsh-workers.zsh.org>
List-Post: <mailto:zsh-workers@zsh.org>
List-Help: <mailto:zsh-workers-help@zsh.org>
X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on f.primenet.com.au
X-Spam-Level: 
X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM,
	T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.0
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=20120113;
        h=mime-version:in-reply-to:references:from:date:message-id:subject:to
         :cc:content-type;
        bh=08bEqpcWVvaVIOD8WdTqnlSpseVXH/MhcRH1gz53HLU=;
        b=1I5nKgYm2u/Y1WJRT8FyYr+7MaSgU7u+HVysbGclG0Utf6fdNWU1AaS2cxZG4K54Dk
         esIeh92K2DbiXs5e3i7U++PX6cQ7B82zCBFBtT5RLR6myDMPQZeK/eRutyxWWdE6A3hn
         wrPR+3ZiXdTIMV4TEUcbNZSNUG1wuuUSjR6E38nQKz7POGq5RBLF8+9Ysm+2kS8KCQHW
         Lu00cB8cuenH5hvqiut41cUNO2k8gdkkJoYx8OomwCZF3kMLQENt3Pa3KCyQlHuIuWf8
         Qx/axQ98iFFRnCws53iVUVM/hF3dAajIMXGaXc9Go4NU/529Tv4fx4H/fLu7Lg07B43t
         K6Hg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20130820;
        h=x-gm-message-state:mime-version:in-reply-to:references:from:date
         :message-id:subject:to:cc:content-type;
        bh=08bEqpcWVvaVIOD8WdTqnlSpseVXH/MhcRH1gz53HLU=;
        b=KXevz0Am3+wRQYpu6Kvp3dn8HY+Tc8EDzHv51MXf0zbnd2Bt1DZzMEobrApm6eV95y
         iyGnHJQdAXalU+pZ320quts0dzCJPYqgLNDi2yaV1RyzhPuEU4XT3n3CDZv7LJN/4bT3
         zuVFPDF+So/Fu2NgYa3VZmU/kszc3yul2kEIobbubnjrZbYuAiH4CAnB/yUPkh/CbGFe
         iCQyJT1MgyPemie9G1PNHBPC6GDq+3/e2ufUIkeduHSx1EKT94EZmvxOohKnoBC4Oj7T
         yssqsi3ldD9N1DvvSbT4GNstzl0DZ3jIHJtc1Mk5uXbK5Y4x+fz7IJRkBayOJoubT6Hi
         O5Wg==
X-Gm-Message-State: AG10YOQRPN79utXKTJcqJvReFk9MWsOv6dftfJrEYErb2PjPl6XTO/uTZ+H3igTJ4taCQjLqcioSQXIxqvhdVA==
X-Received: by 10.25.141.129 with SMTP id p123mr3677182lfd.65.1453647591818;
 Sun, 24 Jan 2016 06:59:51 -0800 (PST)
MIME-Version: 1.0
In-Reply-To: <CAKc7PVBXkDJ=kQS-1d+i78fcKRuNnVo=vxorhARB5OskuABgJw@mail.gmail.com>
References: <CAKc7PVByfo51GcVkb_kYgO2D3cWYrcq-p4v8gmyfsaeWU=2new@mail.gmail.com>
 <160122173705.ZM11491@torch.brasslantern.com> <CAKc7PVCywh3fVsvFOUP3Bi27-8o1w30_E73rs8c+Zd4sOqtT8w@mail.gmail.com>
 <CAKc7PVChdTs4WzKf+amXJ9Y7zOpQVSEsVm6pmHK3FcCQy5k-Xw@mail.gmail.com>
 <CAKc7PVD-AAQ2TDQ_V06Sh15xT9=n5u+cU1WXRAk4kGAi16DqPA@mail.gmail.com>
 <CAKc7PVCXvW0PCV_pREMBqvWvVL02qFmnvc+PMcdDArrCuDMjpg@mail.gmail.com>
 <160123093602.ZM14454@torch.brasslantern.com> <160123112004.ZM14739@torch.brasslantern.com>
 <160123120055.ZM14828@torch.brasslantern.com> <CAKc7PVBXkDJ=kQS-1d+i78fcKRuNnVo=vxorhARB5OskuABgJw@mail.gmail.com>
From: Sebastian Gniazdowski <sgniazdowski@gmail.com>
Date: Sun, 24 Jan 2016 15:59:32 +0100
Message-ID: <CAKc7PVAMYWAAShNp3tEg24R9TTV067fOshg9GCqG+Xgaw78OXQ@mail.gmail.com>
Subject: Re: Proof of concept mainstream plugin manager
To: Bart Schaefer <schaefer@brasslantern.com>
Cc: Zsh hackers list <zsh-workers@zsh.org>
Content-Type: text/plain; charset=UTF-8
X-Seq: zsh-workers 37762

Tested 8 plugins:

horosgrisa/autoenv
adolfoabegg/browse-commit
arzzen/calc.plugin.zsh
walesmd/caniuse.plugin.zsh
mollifier/cd-gitroot
mikedacre/cdbk
willghatch/zsh-cdr
rutchkiwi/copyzshell (requires OMZ directory structure simulation)

And they all work. Except maybe for zsh-cdr, which has the following
glitch: when I run my n-cd, select directory, which will cause "cd" to
be called, then _reload_and_run will cause error on line:


"    builtin autoload $=autoload_opts "$func""

That's very weird, as when I display the options right before the line:

    echo "Running with opts: " $=autoload_opts ", for func: $func"

then there is no improper option in $autoload_opts. And, second call
to n-cd works fine... I can workaround this by doing "command cd" in
my tool instead of just "cd", but still, that's a puzzle, what can be
going on? Decided to write about this and move onward testing next
plugins. Here is movie that shows the weird behavior:

https://asciinema.org/a/bn8b73y8t308qimrrxmvxqlc2

Where in Zsh source does "autload" report anything about option "-" ?
Maybe I could apply some patch and build Zsh to see some clues?

PS. ZPlugin proves to be very nice. Very nice to see what plugins do:

https://asciinema.org/a/dtgdzr4wqe9nizreqjlgrjmik

It also confirms that the plugins contain rather naive code, like
after reading Advanced Bash Scripting Guide, however, they rather just
work, like the autoenv plugin. I'm thinking about reporting that
plugin does use binaries like grep or sed, which would give a hint of
how naive the code loaded is.

Best regards,
Sebastian Gniazdowski

