zsh-workers
 help / color / mirror / code / Atom feed
From: Peter Stephenson <p.stephenson@samsung.com>
To: zsh-workers@zsh.org
Subject: Re: Writing a plugin - where to start?
Date: Wed, 05 Mar 2014 12:46:39 +0000	[thread overview]
Message-ID: <20140305124639.47167f22@pwslap01u.europe.root.pri> (raw)
In-Reply-To: <CAGg_VyUcokg7FaPPuOkhhjcgSk1S77W_W1Y=bqNgF-7pENpehQ@mail.gmail.com>

On Tue, 04 Mar 2014 17:31:56 +0100
Timm Bla <tymmm1@gmail.com> wrote:
> I am new to zsh and I want to write a plugin.
> 
> For that I need to be able to change the output of the history.
> So that when the user goes back or forth in the history (with the arrow
> keys for example) my plugin gives back the output the user will see.
> 
> I went through the manual and looked at some other plugins but still don't
> quite know where to start.
> Maybe someone here can point me in the right direction?

From the lack of immediate responses, I think other people have had the
same reaction as I did --- you're going to have to tell us what you're
trying to plug into.

Are you simply trying to make the line editor behaviour different?  In
that case, I suggest reading the zshzle manual page, which explains
about the difference between builtin widgets (editor functions) and user
defined ones, and how you create and use the latter.  For a more
touchy-feely guide to that, see
http://zsh.sourceforge.net/Guide/zshguide04.html#l75 or chapter 14 of
the book "From Bash to Z Shell" (see www.bash2zsh.com)

If that is what the query is about, you have a great deal of flexibility
at your disposal by using shell functions.  This discussion is more
appropriate for the zsh-users list.

If you're trying to change the shell firmware in some more fundamental
way, that may or may not be possible by writing an extension ---
extensions can make use of various hooks in the main shell but only have
limited ability to change built-in behaviour.  So you'd have to spell
out what you're trying to do.

pws


  reply	other threads:[~2014-03-05 12:46 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-04 16:31 Timm Bla
2014-03-05 12:46 ` Peter Stephenson [this message]
2014-03-05 14:06   ` Peter Stephenson
2014-03-06  2:22 ` Bart Schaefer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140305124639.47167f22@pwslap01u.europe.root.pri \
    --to=p.stephenson@samsung.com \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).