zsh-workers
 help / color / mirror / code / Atom feed
From: Oliver Kiddle <okiddle@yahoo.co.uk>
To: Zsh workers <zsh-workers@zsh.org>
Subject: PATCH: fix nslookup function
Date: Sat, 18 Jul 2015 08:34:22 +0200	[thread overview]
Message-ID: <15371.1437201262@thecus.kiddle.eu> (raw)

At some point nslookup stopped printing the name and IP of the default
DNS server when you start it. This breaks our nslookup function. The
function is an example zpty based wrapper around a REPL style program
which uses vared to allow you to use the zsh line editor for nslookup.
The following fix will also work with an old nslookup.

Oliver

diff --git a/Functions/Misc/nslookup b/Functions/Misc/nslookup
index 150bd03..8c11909 100644
--- a/Functions/Misc/nslookup
+++ b/Functions/Misc/nslookup
@@ -26,8 +26,7 @@ zstyle -s ':nslookup' pager tmp &&
 
 zpty nslookup command nslookup "${(q)@}"
 
-zpty -r nslookup line '*
-> '
+zpty -r nslookup line '*> '
 print -nr "$line"
 
 while line=''; vared -he "$pmpt[@]" line; do


                 reply	other threads:[~2015-07-18  6:41 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=15371.1437201262@thecus.kiddle.eu \
    --to=okiddle@yahoo.co.uk \
    --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).