zsh-workers
 help / color / mirror / code / Atom feed
* [PATCH] zed fails with setopt nounset unless option -x is given
@ 2022-05-20 14:06 Risto Laitinen
  2022-05-20 14:17 ` Peter Stephenson
  0 siblings, 1 reply; 5+ messages in thread
From: Risto Laitinen @ 2022-05-20 14:06 UTC (permalink / raw)
  To: zsh-workers

[-- Attachment #1: Type: text/plain, Size: 95 bytes --]

% zsh-5.9 -f
% autoload zed
% setopt nounset
% zed a.txt
zed:21: opts[-x]: parameter not set
%

[-- Attachment #2: 0001-zed-nounset.txt --]
[-- Type: text/plain, Size: 369 bytes --]

--- Functions/Misc/zed.orig	2022-05-20 16:45:13.709144850 +0300
+++ Functions/Misc/zed	2022-05-20 16:45:56.313326625 +0300
@@ -18,7 +18,7 @@
 fun=$+opts[-f]
 hist=$+opts[-h]
 bind=$+opts[-b]
-if [[ $opts[-x] == <-> ]]; then
+if [[ ${opts[-x]-} == <-> ]]; then
   expand=(-x $opts[-x])
 elif (( $+opts[-x] )); then
   print -r "Integer expected after -x: $opts[-x]" >&2

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-05-25  9:49 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-20 14:06 [PATCH] zed fails with setopt nounset unless option -x is given Risto Laitinen
2022-05-20 14:17 ` Peter Stephenson
2022-05-20 14:39   ` Bart Schaefer
2022-05-20 15:00   ` Bart Schaefer
2022-05-25  9:48   ` Peter Stephenson

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).