From 4b85edface379a3575273a2b712d80bd9420d4c9 Mon Sep 17 00:00:00 2001
From: Peter Stephenson
Date: Tue, 28 May 2019 20:53:53 +0100
Subject: 44361: Initialise variables in pattern matching. These are used
recursively and it's a bit obscure if there are case where the value can
leak.
---
Src/pattern.c | 22 ++++++++++++----------
1 file changed, 12 insertions(+), 10 deletions(-)
(limited to 'Src/pattern.c')
diff --git a/Src/pattern.c b/Src/pattern.c
index 737f5cdcb..97d488a31 100644
--- a/Src/pattern.c
+++ b/Src/pattern.c
@@ -2030,6 +2030,16 @@ int errsfound; /* Total error count so far */
/**/
int forceerrs; /* Forced maximum error count */
+/*
+ * exactpos is used to remember how far down an exact string we have
+ * matched, if we are doing approximation and can therefore redo from
+ * the same point; we never need to otherwise.
+ *
+ * exactend is a pointer to the end of the string, which isn't
+ * null-terminated.
+ */
+static char *exactpos, *exactend;
+
/**/
void
pattrystart(void)
@@ -2463,6 +2473,8 @@ pattryrefs(Patprog prog, char *string, int stringlen, int unmetalenin,
patinput = patinstart;
+ exactpos = exactend = NULL;
+ /* The only external call to patmatch --- all others are recursive */
if (patmatch((Upat)progstr)) {
/*
* we were lazy and didn't save the globflags if an exclusion
@@ -2652,16 +2664,6 @@ patmatchlen(void)
#define CHARMATCH_EXPR(expr, chpa) \
(charmatch_cache = (expr), CHARMATCH(charmatch_cache, chpa))
-/*
- * exactpos is used to remember how far down an exact string we have
- * matched, if we are doing approximation and can therefore redo from
- * the same point; we never need to otherwise.
- *
- * exactend is a pointer to the end of the string, which isn't
- * null-terminated.
- */
-static char *exactpos, *exactend;
-
/*
* Main matching routine.
*
--
cgit v1.2.3
From c578f0a08b9257f3db85dab5431270f1a6eb8858 Mon Sep 17 00:00:00 2001
From: Martijn Dekker
Date: Tue, 10 Dec 2019 20:41:08 +0100
Subject: 45004: Fix typos in comments
---
ChangeLog | 9 +++++++++
Src/builtin.c | 4 ++--
Src/compat.c | 4 ++--
Src/exec.c | 2 +-
Src/glob.c | 4 ++--
Src/hashtable.c | 2 +-
Src/hist.c | 4 ++--
Src/init.c | 6 +++---
Src/jobs.c | 2 +-
Src/lex.c | 2 +-
Src/main.c | 4 ++--
Src/mem.c | 2 +-
Src/module.c | 2 +-
Src/params.c | 2 +-
Src/parse.c | 2 +-
Src/pattern.c | 18 +++++++++---------
Src/prompt.c | 2 +-
Src/subst.c | 12 ++++++------
Src/text.c | 2 +-
Src/watch.c | 2 +-
Src/zsh.h | 16 ++++++++--------
Test/A02alias.ztst | 2 +-
Test/C01arith.ztst | 2 +-
Test/C02cond.ztst | 2 +-
Test/D03procsubst.ztst | 2 +-
Test/D06subscript.ztst | 4 ++--
Test/D08cmdsubst.ztst | 2 +-
Test/E01options.ztst | 2 +-
Test/V10private.ztst | 2 +-
29 files changed, 65 insertions(+), 56 deletions(-)
(limited to 'Src/pattern.c')
diff --git a/ChangeLog b/ChangeLog
index e9fe1e78a..434318f27 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,14 @@
2019-12-11 Martijn Dekker
+ * 45004: Src/builtin.c, Src/compat.c, Src/exec.c, Src/glob.c,
+ Src/hashtable.c, Src/hist.c, Src/init.c, Src/jobs.c,
+ Src/lex.c, Src/main.c, Src/mem.c, Src/module.c, Src/params.c,
+ Src/parse.c, Src/pattern.c, Src/prompt.c, Src/subst.c,
+ Src/text.c, Src/watch.c, Src/zsh.h, Test/A02alias.ztst,
+ Test/C01arith.ztst, Test/C02cond.ztst, Test/D03procsubst.ztst,
+ Test/D06subscript.ztst, Test/D08cmdsubst.ztst,
+ Test/E01options.ztst, Test/V10private.ztst: Fix typos in comments
+
* 45003: Etc/FAQ.yo, Etc/zsh-development-guide,
Functions/Prompts/prompt_oliver_setup,
Functions/Zle/insert-composed-char, NEWS, README: Fix more
diff --git a/Src/builtin.c b/Src/builtin.c
index 18daad4fa..bd7736d2c 100644
--- a/Src/builtin.c
+++ b/Src/builtin.c
@@ -1718,7 +1718,7 @@ fcsubs(char **sp, struct asgment *sub)
newstr = sub->value.scalar;
sub = (Asgment)sub->node.next;
oldpos = s;
- /* loop over occurences of oldstr in s, replacing them with newstr */
+ /* loop over occurrences of oldstr in s, replacing them with newstr */
while ((newpos = (char *)strstr(oldpos, oldstr))) {
newmem = (char *) zhalloc(1 + (newpos - s)
+ strlen(newstr) + strlen(newpos + strlen(oldstr)));
@@ -2526,7 +2526,7 @@ typeset_single(char *cname, char *pname, Param pm, UNUSED(int func),
* Attempt to assign a scalar value to an array.
* This can happen if the array is special.
* We'll be lenient and guess what the user meant.
- * This is how normal assigment works.
+ * This is how normal assignment works.
*/
if (*asg->value.scalar) {
/* Array with one value */
diff --git a/Src/compat.c b/Src/compat.c
index 02b66a780..8ab335aa1 100644
--- a/Src/compat.c
+++ b/Src/compat.c
@@ -30,8 +30,8 @@
#include "zsh.mdh"
#include "compat.pro"
-/* Return pointer to first occurence of string t *
- * in string s. Return NULL if not present. */
+/* Return pointer to first occurrence of string t *
+ * in string s. Return NULL if not present. */
/**/
#ifndef HAVE_STRSTR
diff --git a/Src/exec.c b/Src/exec.c
index 6014ec9a5..9dc91a71e 100644
--- a/Src/exec.c
+++ b/Src/exec.c
@@ -4299,7 +4299,7 @@ save_params(Estate state, Wordcode pc, LinkList *restore_p, LinkList *remove_p)
(unset(RESTRICTED) || !(pm->node.flags & PM_RESTRICTED))) {
/*
* In this case we're just saving parts of
- * the parameter in a tempory, so use heap allocation
+ * the parameter in a temporary, so use heap allocation
* and don't bother copying every detail.
*/
tpm = (Param) hcalloc(sizeof *tpm);
diff --git a/Src/glob.c b/Src/glob.c
index 92fd64e7c..a367b082b 100644
--- a/Src/glob.c
+++ b/Src/glob.c
@@ -274,7 +274,7 @@ addpath(char *s, int l)
}
/* stat the filename s appended to pathbuf. l should be true for lstat, *
- * false for stat. If st is NULL, the file is only checked for existance. *
+ * false for stat. If st is NULL, the file is only checked for existence. *
* s == "" is treated as s == ".". This is necessary since on most systems *
* foo/ can be used to reference a non-directory foo. Returns nonzero if *
* the file does not exists. */
@@ -566,7 +566,7 @@ scanner(Complist q, int shortcircuit)
continue;
errsfound = errssofar;
if (pattry(p, fn)) {
- /* if this name matchs the pattern... */
+ /* if this name matches the pattern... */
if (pbcwdsav == pathbufcwd &&
strlen(fn) + pathpos - pathbufcwd >= PATH_MAX) {
int err;
diff --git a/Src/hashtable.c b/Src/hashtable.c
index b7baa3142..e210ddeca 100644
--- a/Src/hashtable.c
+++ b/Src/hashtable.c
@@ -996,7 +996,7 @@ printshfuncnode(HashNode hn, int printflags)
* expansion of leading tabs.
* expand = 0 is standard: use hard tabs.
* expand > 0 uses that many spaces.
- * expand < 0 uses no identation.
+ * expand < 0 uses no indentation.
*
* Note this function and the following two are called with
* interrupts queued, so saving and restoring text_expand_tabs
diff --git a/Src/hist.c b/Src/hist.c
index e47be8e15..74116e82f 100644
--- a/Src/hist.c
+++ b/Src/hist.c
@@ -181,7 +181,7 @@ mod_export char *chline;
* To avoid having to modify this every time we modify chline,
* we set it when we push the stack, and unset it when we pop
* the appropriate value off the stack. As it's never modified
- * on the stack this is the only maintainance we ever do on it.
+ * on the stack this is the only maintenance we ever do on it.
* In return, ZLE has to check both zle_chline and (if that's
* NULL) chline to get the current value.
*/
@@ -476,7 +476,7 @@ herrflush(void)
*
* Note that this is a side effect --- this is not the usual reason
* for testing lex_add_raw which is to add the text to a different
- * buffer used when we are actually parsing the command substituion
+ * buffer used when we are actually parsing the command substitution
* (nothing to do with ZLE). Sorry.
*/
while (inbufct && (!strin || lex_add_raw)) {
diff --git a/Src/init.c b/Src/init.c
index 445cd3937..2306d7bdf 100644
--- a/Src/init.c
+++ b/Src/init.c
@@ -137,7 +137,7 @@ loop(int toplevel, int justonce)
else
stophist = hstop;
/*
- * Reset all errors, including user interupts.
+ * Reset all errors, including user interrupts.
* This is what allows ^C in an interactive shell
* to return us to the command line.
*/
@@ -203,7 +203,7 @@ loop(int toplevel, int justonce)
* that would be inconsistent with the case where
* we didn't execute a preexec function. This is
* an implementation detail that an interrupting user
- * does't care about.
+ * doesn't care about.
*/
errflag &= ~ERRFLAG_ERROR;
}
@@ -362,7 +362,7 @@ static void parseopts_setemulate(char *nam, int flags)
* Parse shell options.
*
* If (flags & PARSEARGS_TOPLEVEL):
- * - we are doing shell initilisation
+ * - we are doing shell initialisation
* - nam is the name under which the shell was started
* - set up emulation and standard options based on that.
* Otherwise:
diff --git a/Src/jobs.c b/Src/jobs.c
index c06cb9c79..e7438251e 100644
--- a/Src/jobs.c
+++ b/Src/jobs.c
@@ -1085,7 +1085,7 @@ printjob(Job jn, int lng, int synch)
{
/*
* A subjob still has process, which must finish before
- * further excution of the superjob, which the user wants to
+ * further execution of the superjob, which the user wants to
* know about. So report the status of the subjob as if it
* were the user-visible superjob.
*/
diff --git a/Src/lex.c b/Src/lex.c
index f43bcc7db..1d86da94e 100644
--- a/Src/lex.c
+++ b/Src/lex.c
@@ -2109,7 +2109,7 @@ skipcomm(void)
hist_in_word(1);
} else {
/*
- * Set up for nested command subsitution, however
+ * Set up for nested command substitution, however
* we don't actually need the string until we get
* back to the top level and recover the lot.
* The $() body just appears empty.
diff --git a/Src/main.c b/Src/main.c
index 30eef5a25..bad698ee7 100644
--- a/Src/main.c
+++ b/Src/main.c
@@ -34,7 +34,7 @@
* Support for Cygwin binary/text mode filesystems.
* Peter A. Castro
*
- * This deserves some explaination, because it uses Cygwin specific
+ * This deserves some explanation, because it uses Cygwin specific
* runtime functions.
*
* Cygwin supports the notion of binary or text mode access to files
@@ -43,7 +43,7 @@
* and all. If it's on a text mounted filesystem, Cygwin will strip out
* the CRs. This presents a problem because zsh code doesn't allow for
* CRLF's as line terminators. So, we must force all open files to be
- * in text mode reguardless of the underlying filesystem attributes.
+ * in text mode regardless of the underlying filesystem attributes.
* However, we only want to do this for reading, not writing as we still
* want to write files in the mode of the filesystem. To do this,
* we have two options: augment all {f}open() calls to have O_TEXT added to
diff --git a/Src/mem.c b/Src/mem.c
index 77e4375f0..5951e57ed 100644
--- a/Src/mem.c
+++ b/Src/mem.c
@@ -1120,7 +1120,7 @@ struct m_hdr {
/* length of memory header, length of first field of memory header and
minimal size of a block left free (if we allocate memory and take a
block from the free list that is larger than needed, it must have at
- least M_MIN extra bytes to be splitted; if it has, the rest is put on
+ least M_MIN extra bytes to be split; if it has, the rest is put on
the free list) */
#define M_HSIZE (sizeof(struct m_hdr))
diff --git a/Src/module.c b/Src/module.c
index 33d75ebbd..f41b82f25 100644
--- a/Src/module.c
+++ b/Src/module.c
@@ -442,7 +442,7 @@ add_autobin(const char *module, const char *bnam, int flags)
}
/* Remove the builtin added previously by addbuiltin(). Returns *
- * zero on succes and -1 if there is no builtin with that name. */
+ * zero on success and -1 if there is no builtin with that name. */
/**/
int
diff --git a/Src/params.c b/Src/params.c
index a253a9d8e..da7a6b4c5 100644
--- a/Src/params.c
+++ b/Src/params.c
@@ -3548,7 +3548,7 @@ setiparam(char *s, zlong val)
/*
* Set an integer parameter without forcing creation of an integer type.
- * This is useful if the integer is going to be set to a parmaeter which
+ * This is useful if the integer is going to be set to a parameter which
* would usually be scalar but may not exist.
*/
diff --git a/Src/parse.c b/Src/parse.c
index 53709ac00..de1b27967 100644
--- a/Src/parse.c
+++ b/Src/parse.c
@@ -1811,7 +1811,7 @@ par_simple(int *cmplx, int nr)
for (ptr = str; *ptr; ptr++) {
/*
* We can't treat this as "simple" if it contains
- * expansions that require process subsitution, since then
+ * expansions that require process substitution, since then
* we need process handling.
*/
if (ptr[1] == Inpar &&
diff --git a/Src/pattern.c b/Src/pattern.c
index 97d488a31..95e5a79a0 100644
--- a/Src/pattern.c
+++ b/Src/pattern.c
@@ -156,7 +156,7 @@ typedef union upat *Upat;
* P_BRANCH, but applies to the immediately preceding branch. The code in
* the corresponding branch is followed by a P_EXCSYNC, which simply
* acts as a marker that a P_EXCLUDE comes next. The P_EXCLUDE
- * has a pointer to char embeded in it, which works
+ * has a pointer to char embedded in it, which works
* like P_WBRANCH: if we get to the P_EXCSYNC, and we already matched
* up to the same position, fail. Thus we are forced to backtrack
* on closures in the P_BRANCH if the first attempt was excluded.
@@ -502,7 +502,7 @@ patcompcharsset(void)
}
}
-/* Called before parsing a set of file matchs to initialize flags */
+/* Called before parsing a set of file matches to initialize flags */
/**/
void
@@ -2082,7 +2082,7 @@ patmungestring(char **string, int *stringlen, int *unmetalenin)
}
/*
- * Allocate memeory for pattern match. Note this is specific to use
+ * Allocate memory for pattern match. Note this is specific to use
* of pattern *and* trial string.
*
* Unmetafy a trial string for use in pattern matching, if needed.
@@ -2103,7 +2103,7 @@ patmungestring(char **string, int *stringlen, int *unmetalenin)
* In patstralloc (supplied by caller, must last until last pattry is done)
* unmetalen is the unmetafied length of the string; it will be
* calculated if the input value is negative.
- * unmetalenp is the umetafied length of a path segment preceeding
+ * unmetalenp is the umetafied length of a path segment preceding
* the trial string needed for file mananagement; it is calculated as
* needed so does not need to be initialised.
* alloced is the memory allocated on the heap --- same as return value from
@@ -2237,7 +2237,7 @@ pattrylen(Patprog prog, char *string, int len, int unmetalen,
* depends on both prog *and* the trial string). This should only be
* done if there is no path prefix (pathpos == 0) as otherwise the path
* buffer and unmetafied string may not match. To do this,
- * patallocstr() is callled (use force = 1 to ensure it is alway
+ * patallocstr() is called (use force = 1 to ensure it is always
* unmetafied); paststralloc points to existing storage. Memory is
* on the heap.
*
@@ -2331,7 +2331,7 @@ pattryrefs(Patprog prog, char *string, int stringlen, int unmetalenin,
if (patstralloc->alloced)
{
/*
- * Unmetafied; we need pattern sring that's also unmetafied.
+ * Unmetafied; we need pattern string that's also unmetafied.
* We'll cache it in the patstralloc structure.
* Note it's on the heap.
*/
@@ -2389,7 +2389,7 @@ pattryrefs(Patprog prog, char *string, int stringlen, int unmetalenin,
/*
* Remember the length in case used for ${..#..} etc.
* In this case, we didn't unmetafy the pattern string
- * In the orignal structure, but it might be unmetafied
+ * in the original structure, but it might be unmetafied
* for use with an unmetafied test string.
*/
patinlen = pstrlen;
@@ -2619,10 +2619,10 @@ pattryrefs(Patprog prog, char *string, int stringlen, int unmetalenin,
}
/*
- * Return length of previous succesful match. This is
+ * Return length of previous successful match. This is
* in metafied bytes, i.e. includes a count of Meta characters,
* unless the match was done on an unmetafied string using
- * a patstralloc stuct, in which case it, too is unmetafed.
+ * a patstralloc struct, in which case it too is unmetafied.
* Unusual and futile attempt at modular encapsulation.
*/
diff --git a/Src/prompt.c b/Src/prompt.c
index 7f4d7a70e..b65bfb86b 100644
--- a/Src/prompt.c
+++ b/Src/prompt.c
@@ -163,7 +163,7 @@ promptpath(char *p, int npath, int tilde)
*
* txtchangep gives an integer controlling the attributes of
* the prompt. This is for use in zle to maintain the attributes
- * consistenly. Other parts of the shell should not need to use it.
+ * consistently. Other parts of the shell should not need to use it.
*/
/**/
diff --git a/Src/subst.c b/Src/subst.c
index b132f251b..f887dbd24 100644
--- a/Src/subst.c
+++ b/Src/subst.c
@@ -91,7 +91,7 @@ keyvalpairelement(LinkList list, LinkNode node)
* "flag"s contains PREFORK_* flags, defined in zsh.h.
*
* "ret_flags" is used to return PREFORK_* values from nested parameter
- * substitions. It may be NULL in which case PREFORK_SUBEXP must not
+ * substitutions. It may be NULL in which case PREFORK_SUBEXP must not
* appear in flags; any return value from below will be discarded.
*/
@@ -1548,7 +1548,7 @@ untok_and_escape(char *s, int escapes, int tok_arg)
/*
* See if an argument str looks like a subscript or length following
* a colon and parse it. It must be followed by a ':' or nothing.
- * If this succeeds, expand and return the evaulated expression if
+ * If this succeeds, expand and return the evaluated expression if
* found, else return NULL.
*
* We assume this is what is meant if the first character is not
@@ -1682,7 +1682,7 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int pf_flags,
*/
int wantt = 0;
/*
- * Indicates spliting a string into an array. There aren't
+ * Indicates splitting a string into an array. There aren't
* actually that many special cases for this --- which may
* be why it doesn't work properly; we split in some cases
* where we shouldn't, in particular on the multsubs for
@@ -1732,7 +1732,7 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int pf_flags,
int mods = 0;
/*
* The (z) flag, nothing to do with SH_WORD_SPLIT which is tied
- * spbreak, see above; fairly straighforward in use but c.f.
+ * spbreak, see above; fairly straightforward in use but cf.
* the comment for mods.
*
* This gets set to one of the LEXFLAGS_* values.
@@ -2725,7 +2725,7 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int pf_flags,
* substitution is in quotes) always good enough? Potentially
* we may be OK by now --- all potential `@'s and subexpressions
* have been handled, including any [@] index which comes up
- * by virture of v->isarr being set to SCANPM_ISVAR_AT which
+ * by virtue of v->isarr being set to SCANPM_ISVAR_AT which
* is now in isarr.
*
* However, if we are replacing multsub() with something that
@@ -3110,7 +3110,7 @@ paramsubst(LinkList l, LinkNode n, char **str, int qt, int pf_flags,
/*
* Either loop over an array doing replacements or
- * do the replacment on a string.
+ * do the replacement on a string.
*
* We need an untokenized value for matching.
*/
diff --git a/Src/text.c b/Src/text.c
index a4191bf1a..69530ae79 100644
--- a/Src/text.c
+++ b/Src/text.c
@@ -584,7 +584,7 @@ gettext2(Estate state)
state->pc = end;
if (!nargs) {
/*
- * Unnamed fucntion.
+ * Unnamed function.
* We're not going to pull any arguments off
* later, so skip them now...
*/
diff --git a/Src/watch.c b/Src/watch.c
index cd7dc643d..93b3cb134 100644
--- a/Src/watch.c
+++ b/Src/watch.c
@@ -98,7 +98,7 @@
/*
* In utmpx, the ut_name field is replaced by ut_user.
- * Howver, on some systems ut_name may already be defined this
+ * However, on some systems ut_name may already be defined this
* way for the purposes of utmp.
*/
# ifndef ut_name
diff --git a/Src/zsh.h b/Src/zsh.h
index fc3ed2127..9194ea82c 100644
--- a/Src/zsh.h
+++ b/Src/zsh.h
@@ -455,7 +455,7 @@ enum {
*/
#define FDT_FLOCK_EXEC 6
/*
- * Entry used by a process substition.
+ * Entry used by a process substitution.
* This marker is not tested internally as we associated the file
* descriptor with a job for closing.
*
@@ -1255,7 +1255,7 @@ enum {
/*
* Assignment has value?
* If the assignment is an arrray, then it certainly has a value --- we
- * can only tell if there's an expicit assignment.
+ * can only tell if there's an explicit assignment.
*/
#define ASG_VALUEP(asg) (ASG_ARRAYP(asg) || \
@@ -1444,8 +1444,8 @@ struct builtin {
*/
#define BINF_HANDLES_OPTS (1<<18)
/*
- * Handles the assignement interface. The argv list actually contains
- * two nested litsts, the first of normal arguments, and the second of
+ * Handles the assignment interface. The argv list actually contains
+ * two nested lists, the first of normal arguments, and the second of
* assignment structures.
*/
#define BINF_ASSIGN (1<<19)
@@ -2006,7 +2006,7 @@ enum {
enum {
/*
* Set if the string had whitespace at the start
- * that should cause word splitting against any preceeding string.
+ * that should cause word splitting against any preceding string.
*/
MULTSUB_WS_AT_START = 1,
/*
@@ -2272,9 +2272,9 @@ struct histent {
*/
#define LEXFLAGS_NEWLINE 0x0010
-/******************************************/
-/* Definitions for programable completion */
-/******************************************/
+/*******************************************/
+/* Definitions for programmable completion */
+/*******************************************/
/* Nothing special. */
#define IN_NOTHING 0
diff --git a/Test/A02alias.ztst b/Test/A02alias.ztst
index 99f7aae26..ca415fa39 100644
--- a/Test/A02alias.ztst
+++ b/Test/A02alias.ztst
@@ -129,7 +129,7 @@
setopt ALIAS_FUNC_DEF
eval 'goodalias() { print does now work; }'
isafunc)
-0:ALIAS_FUNC_DEF causes the icky behaviour to be avaliable
+0:ALIAS_FUNC_DEF causes the icky behaviour to be available
>does now work
(alias thisisokthough='thisworks() { print That worked; }'
diff --git a/Test/C01arith.ztst b/Test/C01arith.ztst
index 9dfc065c8..419f45292 100644
--- a/Test/C01arith.ztst
+++ b/Test/C01arith.ztst
@@ -386,7 +386,7 @@
esac)
print after case in subshell)
'
-0:Non-arithmetic subst with command subsitution parse from hell
+0:Non-arithmetic subst with command substitution parse from hell
>yes, this one after case in subshell
print "a$((echo one subst)
diff --git a/Test/C02cond.ztst b/Test/C02cond.ztst
index 4ffb07dd4..4b1ec02f0 100644
--- a/Test/C02cond.ztst
+++ b/Test/C02cond.ztst
@@ -388,7 +388,7 @@ F:Failures in these cases do not indicate a problem in the shell.
eval test $w
print $?
done
-0:test compatability weirdness: treat ! as a string sometimes
+0:test compatibility weirdness: treat ! as a string sometimes
>0
>0
>1
diff --git a/Test/D03procsubst.ztst b/Test/D03procsubst.ztst
index 1ef55821b..8cf4e2a7f 100644
--- a/Test/D03procsubst.ztst
+++ b/Test/D03procsubst.ztst
@@ -26,7 +26,7 @@
>SEcond ViErtE
diff =(cat FILE1) =(cat FILE2)
-1:=(...) substituion
+1:=(...) substitution
>1c1
>< First Second Third Fourth
>---
diff --git a/Test/D06subscript.ztst b/Test/D06subscript.ztst
index 3ea7fb7e4..c1a8d79cf 100644
--- a/Test/D06subscript.ztst
+++ b/Test/D06subscript.ztst
@@ -190,7 +190,7 @@
typeset -ga empty
echo X${${empty##*}[-1]}X
-0:Negative index applied to substition result from empty array
+0:Negative index applied to substitution result from empty array
>XX
print $empty[(i)] $empty[(I)]
@@ -221,7 +221,7 @@
>fimble two three four
print X$array[(R)notfound]X
-0:(R) yuckily returns the first element on failure withe KSH_ZERO_SUBSCRIPT
+0:(R) yuckily returns the first element on failure with KSH_ZERO_SUBSCRIPT
>XfimbleX
unsetopt KSH_ZERO_SUBSCRIPT
diff --git a/Test/D08cmdsubst.ztst b/Test/D08cmdsubst.ztst
index 4e0759e35..04bf698aa 100644
--- a/Test/D08cmdsubst.ztst
+++ b/Test/D08cmdsubst.ztst
@@ -174,6 +174,6 @@
eval '{ OPEN print hi; CLOSE }
var=$({ OPEN print bye; CLOSE}) && print $var'
)
-0:Alias expansion needed in parsing substituions
+0:Alias expansion needed in parsing substitutions
>hi
>bye
diff --git a/Test/E01options.ztst b/Test/E01options.ztst
index 0f6bb3455..c4b101bdb 100644
--- a/Test/E01options.ztst
+++ b/Test/E01options.ztst
@@ -850,7 +850,7 @@
# With non-special command: original value restored
# With special builtin: new value kept
- # With special builtin preceeded by "command": original value restored.
+ # With special builtin preceded by "command": original value restored.
(setopt posixbuiltins
FOO=val0
FOO=val1 true; echo $FOO
diff --git a/Test/V10private.ztst b/Test/V10private.ztst
index 880784e12..a3a63867b 100644
--- a/Test/V10private.ztst
+++ b/Test/V10private.ztst
@@ -104,7 +104,7 @@
private -h path
print X$path
}
-0:privates may hide tied paramters
+0:privates may hide tied parameters
>X
# Deliberate type mismatch here
--
cgit v1.2.3
From 11dbe4c286330f81fae5ac6d5f698f5ddb748710 Mon Sep 17 00:00:00 2001
From: Jens Schleusener
Date: Thu, 9 Jan 2020 13:39:44 +0000
Subject: 45269: Fix misspellings in completions and elsewhere.
---
ChangeLog | 33 +++++++++++++++++++++++
Completion/BSD/Command/_mixerctl | 2 +-
Completion/Darwin/Command/_fs_usage | 2 +-
Completion/Darwin/Type/_mac_files_for_application | 2 +-
Completion/Debian/Command/_sbuild | 2 +-
Completion/Linux/Command/_brctl | 2 +-
Completion/Linux/Command/_findmnt | 2 +-
Completion/Linux/Command/_ltrace | 2 +-
Completion/Mandriva/Command/_urpmi | 6 ++---
Completion/Redhat/Command/_yum | 2 +-
Completion/Unix/Command/_attr | 2 +-
Completion/Unix/Command/_git | 10 +++----
Completion/Unix/Command/_graphicsmagick | 8 +++---
Completion/Unix/Command/_iconv | 2 +-
Completion/Unix/Command/_imagemagick | 10 +++----
Completion/Unix/Command/_links | 2 +-
Completion/Unix/Command/_luarocks | 4 +--
Completion/Unix/Command/_objdump | 4 +--
Completion/Unix/Command/_od | 2 +-
Completion/Unix/Command/_pandoc | 2 +-
Completion/Unix/Command/_ping | 2 +-
Completion/Unix/Command/_pkg-config | 2 +-
Completion/Unix/Command/_postgresql | 2 +-
Completion/Unix/Command/_rubber | 2 +-
Completion/Unix/Command/_transmission | 6 ++---
Completion/Unix/Type/_baudrates | 2 +-
Completion/Unix/Type/_path_files | 2 +-
Etc/FAQ.yo | 2 +-
Functions/Zftp/zfautocheck | 2 +-
Misc/c2z | 2 +-
Src/Modules/curses.c | 2 +-
Src/Modules/db_gdbm.c | 2 +-
Src/Modules/parameter.c | 2 +-
Src/Zle/comp.h | 6 ++---
Src/Zle/compcore.c | 2 +-
Src/Zle/compctl.c | 2 +-
Src/Zle/complete.c | 2 +-
Src/Zle/compresult.c | 2 +-
Src/Zle/computil.c | 2 +-
Src/Zle/zle_keymap.c | 2 +-
Src/Zle/zle_main.c | 2 +-
Src/Zle/zle_refresh.c | 2 +-
Src/pattern.c | 2 +-
Src/zsh.h | 2 +-
Src/ztype.h | 2 +-
Test/B01cd.ztst | 2 +-
Test/D04parameter.ztst | 2 +-
47 files changed, 98 insertions(+), 65 deletions(-)
(limited to 'Src/pattern.c')
diff --git a/ChangeLog b/ChangeLog
index 2e1bfb8ad..64e3ee82f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,36 @@
+2020-01-09 Jens Schleusener
+
+ * 45269: Completion/BSD/Command/_mixerctl,
+ Completion/Darwin/Command/_fs_usage,
+ Completion/Darwin/Type/_mac_files_for_application,
+ Completion/Debian/Command/_sbuild,
+ Completion/Linux/Command/_brctl,
+ Completion/Linux/Command/_findmnt,
+ Completion/Linux/Command/_ltrace,
+ Completion/Mandriva/Command/_urpmi,
+ Completion/Redhat/Command/_yum,
+ Completion/Unix/Command/_attr, Completion/Unix/Command/_git,
+ Completion/Unix/Command/_graphicsmagick,
+ Completion/Unix/Command/_iconv,
+ Completion/Unix/Command/_imagemagick,
+ Completion/Unix/Command/_links,
+ Completion/Unix/Command/_luarocks,
+ Completion/Unix/Command/_objdump, Completion/Unix/Command/_od,
+ Completion/Unix/Command/_pandoc, Completion/Unix/Command/_ping,
+ Completion/Unix/Command/_pkg-config,
+ Completion/Unix/Command/_postgresql,
+ Completion/Unix/Command/_rubber,
+ Completion/Unix/Command/_transmission,
+ Completion/Unix/Type/_baudrates,
+ Completion/Unix/Type/_path_files, Etc/FAQ.yo,
+ Functions/Zftp/zfautocheck, Misc/c2z, Src/Modules/curses.c,
+ Src/Modules/db_gdbm.c, Src/Modules/parameter.c, Src/Zle/comp.h,
+ Src/Zle/compcore.c, Src/Zle/compctl.c, Src/Zle/complete.c,
+ Src/Zle/compresult.c, Src/Zle/computil.c, Src/Zle/zle_keymap.c,
+ Src/Zle/zle_main.c, Src/Zle/zle_refresh.c, Src/pattern.c,
+ Src/zsh.h, Src/ztype.h, Test/B01cd.ztst, Test/D04parameter.ztst:
+ Fix misspellings in completions and elsewhere.
+
2020-01-08 dana
* 45261: Completion/Unix/Command/_gcc: Detect clang-as-gcc
diff --git a/Completion/BSD/Command/_mixerctl b/Completion/BSD/Command/_mixerctl
index a43aed4cb..d2a9ea3ee 100644
--- a/Completion/BSD/Command/_mixerctl
+++ b/Completion/BSD/Command/_mixerctl
@@ -8,4 +8,4 @@ _arguments -s -S -A "-*" \
'(-a -n -v)-q[Suppress all printing when setting a variable]' \
'(-a -n -v)-t[Attempt to select the next possible value of an enum]' \
'(-q -t)-v[Show all possible values of variables]' \
- '(-a)*:mixerctl varible:_multi_parts -i -S = -q . _cache_mixerctlvars'
+ '(-a)*:mixerctl variable:_multi_parts -i -S = -q . _cache_mixerctlvars'
diff --git a/Completion/Darwin/Command/_fs_usage b/Completion/Darwin/Command/_fs_usage
index 956816169..1d76cf86d 100644
--- a/Completion/Darwin/Command/_fs_usage
+++ b/Completion/Darwin/Command/_fs_usage
@@ -6,7 +6,7 @@ typeset -A opt_args
_arguments -s -C -A '-*' : \
'-e[exclude fs_usage and the specified processes from sampling]' \
'-w[use wider output]' \
- '*-f+[specify output filtering mode]:mode:(nework filesys pathname exec diskio cachehit)' \
+ '*-f+[specify output filtering mode]:mode:(network filesys pathname exec diskio cachehit)' \
'-b[annotate disk I/O events with BootCache info]' \
'(-R -S -E)-t+[specify run timeout]:seconds' \
'(-t)-R+[specify raw trace file to process]:raw trace file:_files' \
diff --git a/Completion/Darwin/Type/_mac_files_for_application b/Completion/Darwin/Type/_mac_files_for_application
index 44516b4db..885b064fe 100644
--- a/Completion/Darwin/Type/_mac_files_for_application
+++ b/Completion/Darwin/Type/_mac_files_for_application
@@ -44,7 +44,7 @@ _mac_files_for_application() {
local -a glob_patterns
glob_patterns=()
- # Try to get extentions from "Info.plist" XML file.
+ # Try to get extensions from "Info.plist" XML file.
if [[ -f "$app_path/Contents/Info.plist" ]]; then
local -a exts types
_mac_parse_info_plist
diff --git a/Completion/Debian/Command/_sbuild b/Completion/Debian/Command/_sbuild
index 0cb3dc3b9..b38eda0ee 100644
--- a/Completion/Debian/Command/_sbuild
+++ b/Completion/Debian/Command/_sbuild
@@ -115,7 +115,7 @@ _sbuild() {
'--finished-build-commands=[run commands after package is built]:commands' \
'--build-failed-commands=[run commands after dpkg-buildpackage fails]:commands' \
'--chroot-cleanup-commands=[run commands after chroot cleanup]:commands' \
- '--post-build-commands=[run commands after package is build sucessfuly]:commands' \
+ '--post-build-commands=[run commands after package is build successfully]:commands' \
'--post-build-failed-commands[run commands after package failed to build]:commands' \
'--anything-failed-commands=[run commands for all --xxx-failed-commands option]:commands' \
'--log-external-command-output[external commands output are logged]' \
diff --git a/Completion/Linux/Command/_brctl b/Completion/Linux/Command/_brctl
index 6e65d122c..4d053d5cb 100644
--- a/Completion/Linux/Command/_brctl
+++ b/Completion/Linux/Command/_brctl
@@ -13,7 +13,7 @@ if (( CURRENT == 2 )); then
hairpin:toggle\ hairpin\ mode\ on\ a\ port
showmacs:show\ a\ list\ of\ learned\ MAC\ addresses
setageing:set\ MAC\ address\ ageing\ time
- setgcint:set\ grabage\ collection\ interval
+ setgcint:set\ garbage\ collection\ interval
stp:control\ use\ of\ spanning\ tree\ protocol
showstp:show\ bridge\ stp\ info
setbridgeprio:set\ bridge\ priority
diff --git a/Completion/Linux/Command/_findmnt b/Completion/Linux/Command/_findmnt
index 1e570aabd..9f13e695f 100644
--- a/Completion/Linux/Command/_findmnt
+++ b/Completion/Linux/Command/_findmnt
@@ -32,7 +32,7 @@ _arguments -s -C \
'(H -U --uniq)'{-U,--uniq}'[ignore filesystems with duplicated mount targets]' \
'(H -u --notruncate)'{-u,--notruncate}'[do not truncate text in columns]' \
'(H -v --nofsroot)'{-v,--nofsroot}'[do not print \[/dir\] in the SOURCE column]' \
- '(H -w --timeout)'{-w+,--timeout}'[specify timeout for --poll]:miliseconds: ' \
+ '(H -w --timeout)'{-w+,--timeout}'[specify timeout for --poll]:milliseconds: ' \
'(H -x --verify)'{-x,--verify}'[check mount table content]' \
'(H)--verbose[print more information]' \
'(H)1: :->sources_targets' \
diff --git a/Completion/Linux/Command/_ltrace b/Completion/Linux/Command/_ltrace
index e48d8ec98..b60f8c355 100644
--- a/Completion/Linux/Command/_ltrace
+++ b/Completion/Linux/Command/_ltrace
@@ -5,7 +5,7 @@ local root hlp="-h --help -V --version"
(( EUID )) && root='!'
_arguments -s -S $args \
- "(-c -a --align $hlp)"{-a+,--align=}"[align return values in a secific column]:column [$((COLUMNS*5/8))]" \
+ "(-c -a --align $hlp)"{-a+,--align=}"[align return values in a specific column]:column [$((COLUMNS*5/8))]" \
"(-c $hlp)-A+[specify maximum number of array elements to print]:elements" \
"(-c -b --no-signals $hlp)"{-b,--no-signals}"[don't print signals]" \
"(-a --align -A -b --no-signals -i -n --indent -r -s -t -tt -ttt -T $hlp)-c[count time and calls, and report a summary on exit]" \
diff --git a/Completion/Mandriva/Command/_urpmi b/Completion/Mandriva/Command/_urpmi
index 00994c70f..d897f2c4b 100644
--- a/Completion/Mandriva/Command/_urpmi
+++ b/Completion/Mandriva/Command/_urpmi
@@ -87,7 +87,7 @@ _urpmi() {
"($help)--auto[automatically select a package in choices]"
"($help)--force[force invocation even if some packages do not exist]"
"($help)--parallel[distributed urpmi across machines of alias]:urpmi alias name:_urpmi_parallel_alias"
- "($help)--root[use another root for rpm installation]:root diretory:_files -/"
+ "($help)--root[use another root for rpm installation]:root directory:_files -/"
"($help)--test[test only, do not modify system]"
"($help)-a[select all matches on command line]"
)
@@ -147,7 +147,7 @@ _urpmi() {
"($help : -)"{--help,-h}"[print usage information]" \
"($help :)-a[select all media]" \
"($help)-c[clean headers cache directory]" \
- "($help)-y[fuzzy mathing on media names]" \
+ "($help)-y[fuzzy matching on media names]" \
"(-a)"{,\*}":media:_sequence _urpmi_media" \
&& ret=0
;;
@@ -189,7 +189,7 @@ _urpmi() {
"($help)--more-choices[propose more choices than the default]" \
"($help --no-resume)--resume[resume transfer of partially-downloaded files]" \
"($help --resume)--no-resume[do not resume transfer of partially-downloaded files]" \
- "($help)--root[use another root for rpm installation]:root diretory:_files -/" \
+ "($help)--root[use another root for rpm installation]:root directory:_files -/" \
"($help)--skip[packages which installation should be skipped]:packages: " \
"($help)--split-length[small transaction length]:transaction length: " \
"($help)--split-level[split in small transaction]:transaction size: " \
diff --git a/Completion/Redhat/Command/_yum b/Completion/Redhat/Command/_yum
index 8abd23ebb..a30aa579f 100644
--- a/Completion/Redhat/Command/_yum
+++ b/Completion/Redhat/Command/_yum
@@ -39,7 +39,7 @@ _yum() {
'--color=[control whether color is used]:(always auto never)' \
'--releasever=[set value of $releasever in yum config and repo files]:value' \
"--downloadonly[don't update, just download]" \
- '--downloaddir=[specify alternate directory to store packages]:directort:_directories' \
+ '--downloaddir=[specify alternate directory to store packages]:directory:_directories' \
'--setopt=[set arbitrary config and repo options]:option' \
'--bugfix[include bugfix relevant packages in updates]' \
'--security[include security relevant packages in updates]' \
diff --git a/Completion/Unix/Command/_attr b/Completion/Unix/Command/_attr
index d8d4ed260..121c0c539 100644
--- a/Completion/Unix/Command/_attr
+++ b/Completion/Unix/Command/_attr
@@ -56,7 +56,7 @@ case $service in
'-r[act recursively]' \
'-s[act on symbolic links]' \
'(-w)-v[always display file name]' \
- '(-c -d)-x[use hexademical format for value input and output]' \
+ '(-c -d)-x[use hexadecimal format for value input and output]' \
'*: :_files' \
+ '(op)' \
'(-l -x)-c[remove all attributes]' \
diff --git a/Completion/Unix/Command/_git b/Completion/Unix/Command/_git
index be0c810cc..40d10f431 100644
--- a/Completion/Unix/Command/_git
+++ b/Completion/Unix/Command/_git
@@ -1187,7 +1187,7 @@ _git-log () {
fi
# TODO: Write a wrapper function that checks whether we have a
- # committish range or comittish and calls __git_tree_files
+ # committish range or committish and calls __git_tree_files
# appropriately.
if __git_is_committish_range $line[1]; then
__git_tree_files ${PREFIX:-.} $(__git_committish_range_last $line[1]) && ret=0
@@ -1671,7 +1671,7 @@ _git-shortlog () {
;;
(*)
# TODO: Write a wrapper function that checks whether we have a
- # committish range or comittish and calls __git_tree_files
+ # committish range or committish and calls __git_tree_files
# appropriately.
if __git_is_committish_range $line[1]; then
__git_tree_files ${PREFIX:-.} $(__git_committish_range_last $line[1]) && ret=0
@@ -2101,7 +2101,7 @@ _git-switch() {
case $state in
branches)
if [[ -n ${opt_args[(i)--guess]} ]]; then
- # --guess is the default but if it has been explictly specified,
+ # --guess is the default but if it has been explicitly specified,
# we'll only complete remote branches
__git_remote_branch_names_noprefix && ret=0
else
@@ -5432,7 +5432,7 @@ _git-daemon () {
'--strict-paths[match paths exactly]' \
'--access-hook=-[allow an external tool to accept or decline service]:path:_directories' \
'--base-path=-[remap all the path requests as relative to the given path]:path:_directories' \
- '--base-path-relaxed[allow lookup of base path witout prefix]' \
+ '--base-path-relaxed[allow lookup of base path without prefix]' \
'--interpolated-path=-[dynamically construct alternate paths]:path:_directories' \
'--export-all[allow pulling from all repositories without verification]' \
'(--port --listen --user --group)--inetd[run server as an inetd service]' \
@@ -6100,7 +6100,7 @@ _git_column_layouts() {
'(always never)auto[show in columns if the output is to the terminal]' \
'(row plain)column[fill columns before rows]' \
'(column plain)row[fill rows before columns]' \
- '(column row)plain[show in one colum]' \
+ '(column row)plain[show in one column]' \
'(nodense)dense[make unequal size columns to utilize more space]' \
'(dense)nodense[make equal size columns]'
}
diff --git a/Completion/Unix/Command/_graphicsmagick b/Completion/Unix/Command/_graphicsmagick
index cc541d891..dc799085b 100644
--- a/Completion/Unix/Command/_graphicsmagick
+++ b/Completion/Unix/Command/_graphicsmagick
@@ -40,7 +40,7 @@ case "$words[2]" in
'*-dispose:GIF disposal method:((0:no\ disposal 1\:don'\''t\ dispose\ between\ frames 2\:overwrite\ frame\ with\ background\ color 3\:overwrite\ with\ previous\ frame))' \
'*-dither[apply dithering]' \
'*-edge:edge detection factor (0.0 - 99.9%%)' \
- '*-endian:image endianess:(MSB LSB)' \
+ '*-endian:image endianness:(MSB LSB)' \
'*+endian' \
'*-enhance[enhance noisy image]' \
'*-filter:filter type for resizing:(Point Box Triangle Hermite Hanning Hamming Blackman Gaussian Quadratic Cubic Catrom Mitchell Lanczos Bessel Sinc)' \
@@ -162,7 +162,7 @@ case "$words[2]" in
'-descend[descend window hierarchy]' \
'-dispose:GIF disposal method:((0:no\ disposal 1\:don'\''t\ dispose\ between\ frames 2\:overwrite\ frame\ with\ background\ color 3\:overwrite\ with\ previous\ frame))' \
'-dither[apply dithering]' \
- '(+endian)-endian:image endianess:(MSB LSB)' \
+ '(+endian)-endian:image endianness:(MSB LSB)' \
'(-endian)+endian' \
'-frame[include window manager frame]' \
'(- *)-help[display help information]' \
@@ -214,7 +214,7 @@ case "$words[2]" in
'*-dither[apply dithering]' \
'*+dither[render Postscript without aliasing]' \
'*-draw:drawing primitive:compadd -S "\\ " - rectangle circle ellipse polygon color matte text image' \
- '*-endian:image endianess:(MSB LSB)' \
+ '*-endian:image endianness:(MSB LSB)' \
'*+endian' \
'*-filter:filter type for resizing:(Point Box Triangle Hermite Hanning Hamming Blackman Gaussian Quadratic Cubic Catrom Mitchell Lanczos Bessel Sinc)' \
'*-frame[draw frame around image]' \
@@ -293,7 +293,7 @@ case "$words[2]" in
'-draw:drawing primitive:compadd -S "\\ " - rectangle circle ellipse polygon color matte text image' \
'-edge:edge detection factor (0.0 - 99.9%%)' \
'-emboss[emboss image]' \
- '(+endian)-endian:image endianess:(MSB LSB)' \
+ '(+endian)-endian:image endianness:(MSB LSB)' \
'(-endian)+endian' \
'-enhance[enhance image]' \
'-equalize[histogram equalization]' \
diff --git a/Completion/Unix/Command/_iconv b/Completion/Unix/Command/_iconv
index e6daad938..bf04acfe4 100644
--- a/Completion/Unix/Command/_iconv
+++ b/Completion/Unix/Command/_iconv
@@ -38,7 +38,7 @@ if _pick_variant -r variant libiconv='GNU*libiconv' glibc='(Free Soft|GNU*libc|G
_arguments -C -S -s : $args && return 0
if [[ $state = *_codeset ]]; then
- # suffix is meaningfull only for output encoding
+ # suffix is meaningful only for output encoding
if [[ $state = to_codeset ]] && compset -P '*[^/]/'; then
_wanted suffix expl suffix compadd "$@" /TRANSLIT /IGNORE && ret=0
else
diff --git a/Completion/Unix/Command/_imagemagick b/Completion/Unix/Command/_imagemagick
index c2c9dc478..3afa108ae 100644
--- a/Completion/Unix/Command/_imagemagick
+++ b/Completion/Unix/Command/_imagemagick
@@ -44,7 +44,7 @@ case "$service" in
'*-dispose:GIF disposal method:((0:no\ disposal 1\:don'\''t\ dispose\ between\ frames 2\:overwrite\ frame\ with\ background\ color 3\:overwrite\ with\ previous\ frame))' \
'*-dither[apply dithering]' \
'*-edge:edge detection factor (0.0 - 99.9%%)' \
- '*-endian:image endianess:(MSB LSB)' \
+ '*-endian:image endianness:(MSB LSB)' \
'*+endian' \
'*-enhance[enhance noisy image]' \
'*-filter:filter type for resizing:(Point Box Triangle Hermite Hanning Hamming Blackman Gaussian Quadratic Cubic Catrom Mitchell Lanczos Bessel Sinc)' \
@@ -166,7 +166,7 @@ case "$service" in
'-descend[descend window hierarchy]' \
'-dispose:GIF disposal method:((0:no\ disposal 1\:don'\''t\ dispose\ between\ frames 2\:overwrite\ frame\ with\ background\ color 3\:overwrite\ with\ previous\ frame))' \
'-dither[apply dithering]' \
- '(+endian)-endian:image endianess:(MSB LSB)' \
+ '(+endian)-endian:image endianness:(MSB LSB)' \
'(-endian)+endian' \
'-frame[include window manager frame]' \
'(- *)-help[display help information]' \
@@ -218,7 +218,7 @@ case "$service" in
'*-dither[apply dithering]' \
'*+dither[render Postscript without aliasing]' \
'*-draw:drawing primitive:compadd -S "\\ " - rectangle circle ellipse polygon color matte text image' \
- '*-endian:image endianess:(MSB LSB)' \
+ '*-endian:image endianness:(MSB LSB)' \
'*+endian' \
'*-filter:filter type for resizing:(Point Box Triangle Hermite Hanning Hamming Blackman Gaussian Quadratic Cubic Catrom Mitchell Lanczos Bessel Sinc)' \
'*-frame[draw frame around image]' \
@@ -297,7 +297,7 @@ case "$service" in
'-draw:drawing primitive:compadd -S "\\ " - rectangle circle ellipse polygon color matte text image' \
'-edge:edge detection factor (0.0 - 99.9%%)' \
'-emboss[emboss image]' \
- '(+endian)-endian:image endianess:(MSB LSB)' \
+ '(+endian)-endian:image endianness:(MSB LSB)' \
'(-endian)+endian' \
'-enhance[enhance image]' \
'-equalize[histogram equalization]' \
@@ -511,7 +511,7 @@ case "$service" in
'-file:output file:_files' \
'-get[get files]' \
'-port:port: _ports' \
- '-proxy:host of proxy ftp deamon:_hosts' \
+ '-proxy:host of proxy ftp daemon:_hosts' \
'-print[print files]' \
'-prune[process files from remote directory]' \
'-put[put files]' \
diff --git a/Completion/Unix/Command/_links b/Completion/Unix/Command/_links
index 3f55e9c8b..495937709 100644
--- a/Completion/Unix/Command/_links
+++ b/Completion/Unix/Command/_links
@@ -37,7 +37,7 @@ _arguments -C \
'-memory-cache-size[cache memory]:size (bytes) [1048576]' \
'-image-cache-size[image cache memory]:size (bytes) [1048576]' \
'-font-cache-size[specify font cache size]:size (bytes) [2097152]' \
- "-aggressive-cache[cache everything regardless of server's caching recomendations]:enable [1]:((1\\:on 0\\:off))" \
+ "-aggressive-cache[cache everything regardless of server's caching recommendations]:enable [1]:((1\\:on 0\\:off))" \
'-address-preference[specify IP version preference]:preference:((
0\:system\ default
1\:prefer\ IPv4
diff --git a/Completion/Unix/Command/_luarocks b/Completion/Unix/Command/_luarocks
index c73a75a03..0b8e45803 100644
--- a/Completion/Unix/Command/_luarocks
+++ b/Completion/Unix/Command/_luarocks
@@ -135,7 +135,7 @@ ___luarocks_installed_rocks_cache_policy(){
# ) if configuration files are newer:
# * set and cache the values from the commands above
# ) else:
- # * retrive from cache the values of the commands above
+ # * retrieve from cache the values of the commands above
# ) end if
# ) end if
@@ -190,7 +190,7 @@ ___luarocks_installed_rocks_cache_policy(){
}
(( $+functions[__luarocks_installed_rocks] )) ||
__luarocks_installed_rocks(){
- # This function optionally recieves one argument of the tree in which
+ # This function optionally receives one argument of the tree in which
# installed rocks are searched for. If this argument is used, the installed
# rocks which will be completed by this function will not use the cache which
# is valid only for installed rocks on default trees like /usr/lib/luarocks
diff --git a/Completion/Unix/Command/_objdump b/Completion/Unix/Command/_objdump
index 987b10bb0..989cd3f0b 100644
--- a/Completion/Unix/Command/_objdump
+++ b/Completion/Unix/Command/_objdump
@@ -52,8 +52,8 @@ case $variant in
'(-m --architecture)'{-m+,--architecture=}'[specify the target architecture]:architecture:->architectures'
\*{-M+,--disassembler-options=}'[pass target specific information to the disassembler]:option:->disassembler_options'
- "(-E --endian)-E+[assume endianess when disassembling]:endianess:((B\:\"assume big endian format when disassembling\" L\:\"assume little endian format when disassembling\"))"
- "(-E --endian)--endian=[assume endianess when disassembling]:endianess:((big\:\"assume big endian format when disassembling\" little\:\"assume little endian format when disassembling\"))"
+ "(-E --endian)-E+[assume endianness when disassembling]:endianness:((B\:\"assume big endian format when disassembling\" L\:\"assume little endian format when disassembling\"))"
+ "(-E --endian)--endian=[assume endianness when disassembling]:endianness:((big\:\"assume big endian format when disassembling\" little\:\"assume little endian format when disassembling\"))"
'--file-start-context[include context from start of file (with -S)]'
\*{-I+,--include=}'[add directory to search list for source files]:directory:_files -/'
diff --git a/Completion/Unix/Command/_od b/Completion/Unix/Command/_od
index 046018131..7673a225b 100644
--- a/Completion/Unix/Command/_od
+++ b/Completion/Unix/Command/_od
@@ -26,7 +26,7 @@ if _pick_variant gnu=GNU unix --version; then
args=( ${(R)args:#(|\*)(|\(*\))-[hBIL]*} )
args+=(
'--traditional'
- '--endian=[swap input bytes]:endianess:(big little)'
+ '--endian=[swap input bytes]:endianness:(big little)'
{-S+,--strings=-}'[output strings of at least specified bytes long]:length'
{-w-,--width=-}'[output specified bytes per line]:bytes'
'(- : *)--help[display help and exit]'
diff --git a/Completion/Unix/Command/_pandoc b/Completion/Unix/Command/_pandoc
index d70d3cf0a..24fee9969 100644
--- a/Completion/Unix/Command/_pandoc
+++ b/Completion/Unix/Command/_pandoc
@@ -335,7 +335,7 @@ _arguments -C \
'--data-dir=[specify the user data directory to search for pandoc data files]:dir:_pandoc_data_dir' \
'--base-header-level=[specify the base level for headers (defaults to 1)]:number:_pandoc_header_level' \
'--strip-empty-paragraphs[deprecated. Use the +empty_paragraphs extension instead]: :' \
- '--indented-code-classes=[classes to use for indented code blocks]:class:{_message "Classes seperated with ,"}' \
+ '--indented-code-classes=[classes to use for indented code blocks]:class:{_message "Classes separated with ,"}' \
'*--filter=[specify an executable to be used as a filter transforming the pandoc AST after the input is parsed and before the output is written]:file:_pandoc_filter' \
'*--lua-filter=[transform the document in a similar fashion as JSON filters (see --filter), but use pandoc'"'"'s build-in lua filtering system]:file:_pandoc_lua_filter' \
{-p,--preserve-tabs}'[preserve tabs instead of converting them to spaces]: :' \
diff --git a/Completion/Unix/Command/_ping b/Completion/Unix/Command/_ping
index 3cb6e1008..274204264 100644
--- a/Completion/Unix/Command/_ping
+++ b/Completion/Unix/Command/_ping
@@ -139,7 +139,7 @@ case ${variant}:${${service#ping}:-4} in
darwin*:6)
args+=(
'-B+[bind the socket to specified interface for sending]:interface:_net_interfaces'
- '-G+[specify max,min,increment size for ICMP payload for sweeping pings]:max,min,incr (defalt min=0 incr=1)'
+ '-G+[specify max,min,increment size for ICMP payload for sweeping pings]:max,min,incr (default min=0 incr=1)'
'-z+[specify traffic class]:traffic class'
)
;|
diff --git a/Completion/Unix/Command/_pkg-config b/Completion/Unix/Command/_pkg-config
index 43773967e..cae6a6293 100644
--- a/Completion/Unix/Command/_pkg-config
+++ b/Completion/Unix/Command/_pkg-config
@@ -36,7 +36,7 @@ arguments=(
"--print-requires[list all modules the package requires]"
"--print-requires-private[list all modules the package requires for static linking (see --static)]"
# "--msvc-syntax[output linker flags in a form compatible with MSVC++ (Windows only)]"
-# "--dont-define-prefix[disables automatic overiding of the variable \"prefix\" (Windows only)]"
+# "--dont-define-prefix[disables automatic overriding of the variable \"prefix\" (Windows only)]"
# "--prefix-variable=[set the name of the variable \"prefix\" (Windows only)]:prefix value"
"*: :->packages"
)
diff --git a/Completion/Unix/Command/_postgresql b/Completion/Unix/Command/_postgresql
index f0c70a164..595eb1cb4 100644
--- a/Completion/Unix/Command/_postgresql
+++ b/Completion/Unix/Command/_postgresql
@@ -610,7 +610,7 @@ _pgsql_initdb() {
+ x # Exclusive options
$common_opts_excl
+ '(l)' # Locale options (general)
- {-l+,--locale=}'[specify locale (all catgories)]: :_locales'
+ {-l+,--locale=}'[specify locale (all categories)]: :_locales'
'--no-locale[equivalent to --locale=C]'
+ lc # Locale options (specific) -- unlike createdb, NOT exclusive with -l
'--lc-collate=[specify LC_COLLATE setting]: :_locales'
diff --git a/Completion/Unix/Command/_rubber b/Completion/Unix/Command/_rubber
index f66540a9f..bd97470dd 100644
--- a/Completion/Unix/Command/_rubber
+++ b/Completion/Unix/Command/_rubber
@@ -59,7 +59,7 @@ case "$service" in
'--boxes[report overfull and underfull boxes]' \
'--check[report errors or warnings default action]' \
'--deps[show the target file s dependencies]' \
- '--errors[show all errors that occured during compilation]' \
+ '--errors[show all errors that occurred during compilation]' \
'--refs[show the list of undefined references]' \
'--warnings[show all LaTeX warnings]' \
':LaTeX file:_files -g "*.(tex|dtx|lhs|w)(-.)"'
diff --git a/Completion/Unix/Command/_transmission b/Completion/Unix/Command/_transmission
index bd9c44c6f..8a4bebec3 100644
--- a/Completion/Unix/Command/_transmission
+++ b/Completion/Unix/Command/_transmission
@@ -50,7 +50,7 @@ local global_only_actions=(
'(- :)'{-m,--portmap}'[enable portmapping via NAT-PMP or UPnP]'
'(- :)'{-M,--no-portmap}'[disable portmapping]'
'(- :)'{-o,--dht}'[enable distributed hash table]'
- '(- :)'{-O,--no-dht}'[disable distribued hash table]'
+ '(- :)'{-O,--no-dht}'[disable distributed hash table]'
'(- :)'{-u,--uplimit}'[limit the maximum upload speed to limit kB/s]:limit:{_message "limit in kB/sec"}'
'(- :)'{-U,--no-uplimit}'[disable upload speed limits]'
'(- :)--utp[enable uTP for peer connections]'
@@ -69,7 +69,7 @@ local torrent_add_options=(
'(-c --incomplete-dir)'{-C,--no-incomplete-dir}'[don'"'"'t store incomplete torrents in a different directory]'
{-w-,--download-dir=}'[when used in conjunction with --add, set the new torrent'"'"'s download folder]:dir:{_files -/}'
)
-# `torrent_action_only_actions`: *actions* that can be speficied only when explicitly selecting a specific set of torrents
+# `torrent_action_only_actions`: *actions* that can be specified only when explicitly selecting a specific set of torrents
local torrent_action_only_actions=(
{-f,--files}'[get a file list for the current torrent(s)]'
{-g,--get}'[mark file(s) for download]:torrent_file:_transmission-remote_torrent_get'
@@ -154,7 +154,7 @@ _transmission-remote_torrent(){
local torrents_list_lines=(${(f)"$(transmission-remote "${authentication_args}" --list 2> /dev/null)"})
local -a parts
local -a torrents_ids torrents_names
- # While itereating through every line in the output above, we don't need the
+ # While iterating through every line in the output above, we don't need the
# first and last line which are just a header and summary
for (( t = 2; t < ${#torrents_list_lines[@]} - 1; ++t )); do
parts=(${(@s. .)torrents_list_lines[$t]})
diff --git a/Completion/Unix/Type/_baudrates b/Completion/Unix/Type/_baudrates
index 6e9ba4d97..a9d7fe541 100644
--- a/Completion/Unix/Type/_baudrates
+++ b/Completion/Unix/Type/_baudrates
@@ -11,7 +11,7 @@
#
# -l LIMIT Lower limit. Like -u but for the lower boundary.
#
-# -f FUNCTION If given FUNCION is used as a predicate to filter the
+# -f FUNCTION If given FUNCTION is used as a predicate to filter the
# value in the complete list to generate an arbitrary
# sub-set.
#
diff --git a/Completion/Unix/Type/_path_files b/Completion/Unix/Type/_path_files
index 19ae59629..06d9d8d51 100644
--- a/Completion/Unix/Type/_path_files
+++ b/Completion/Unix/Type/_path_files
@@ -425,7 +425,7 @@ for prepath in "$prepaths[@]"; do
tmp1=( "$prepath$realpath$donepath$tmp2" )
- # count of attemps for pws non-canonical hack
+ # count of attempts for pws non-canonical hack
(( npathcheck = 0 ))
while true; do
diff --git a/Etc/FAQ.yo b/Etc/FAQ.yo
index 5c28b4089..d1f8b7d83 100644
--- a/Etc/FAQ.yo
+++ b/Etc/FAQ.yo
@@ -2244,7 +2244,7 @@ sect(What is multibyte input?)
zsh will be able to use any such encoding as long as it contains ASCII as
a single-octet subset and the system can provide information about other
characters. However, in the case of Unicode, UTF-8 is the only one you
- are likely to enounter that is useful in zsh.
+ are likely to encounter that is useful in zsh.
(In case you're confused: Unicode is the character set, while UTF-8 is
an encoding of it. You might hear about other encodings, such as UCS-2
diff --git a/Functions/Zftp/zfautocheck b/Functions/Zftp/zfautocheck
index e53fde8d2..a8b24ef0b 100644
--- a/Functions/Zftp/zfautocheck
+++ b/Functions/Zftp/zfautocheck
@@ -4,7 +4,7 @@
# With first argument including n, don't change to the old directory; else do.
#
# Set do_close to 1 if the connection was not previously open, 0 otherwise
-# With first arguemnt including d, don't set do_close to 1. Broadly
+# With first argument including d, don't set do_close to 1. Broadly
# speaking, we use this mechanism to shut the connection after use
# if the connection had been explicitly closed (i.e. didn't time out,
# which zftp test investigates) and we are not using a directory
diff --git a/Misc/c2z b/Misc/c2z
index 534137296..ce699da8a 100755
--- a/Misc/c2z
+++ b/Misc/c2z
@@ -10,7 +10,7 @@
# uses the csh to parse its own dot-files, then processes csh output to
# convert the csh settings to zsh.
#
-# When run as a zsh fuction, c2z runs csh as if it were an interactive
+# When run as a zsh function, c2z runs csh as if it were an interactive
# shell whenever the parent zsh is interactive. When run as a shell
# script, the -i switch can be used to force this behavior.
#
diff --git a/Src/Modules/curses.c b/Src/Modules/curses.c
index a60dfcbf8..19f285e34 100644
--- a/Src/Modules/curses.c
+++ b/Src/Modules/curses.c
@@ -1519,7 +1519,7 @@ zccmd_resize(const char *nam, char **args)
// is not available.
return 0;
} else {
- // Without this call some window moves are innacurate. Tested on
+ // Without this call some window moves are inaccurate. Tested on
// OS X ncurses 5.4, Homebrew ncursesw 6.0-2, Arch Linux ncursesw
// 6.0, Ubuntu 14.04 ncurses 5.9, FreeBSD ncursesw.so.8
//
diff --git a/Src/Modules/db_gdbm.c b/Src/Modules/db_gdbm.c
index 12dd839cf..b8e7c76c6 100644
--- a/Src/Modules/db_gdbm.c
+++ b/Src/Modules/db_gdbm.c
@@ -766,7 +766,7 @@ static int remove_tied_name( const char *name ) {
/*
* Unmetafy that:
- * - duplicates bufer to work on it,
+ * - duplicates buffer to work on it,
* - does zalloc of exact size for the new string,
* - restores work buffer to original content, to restore strlen
*/
diff --git a/Src/Modules/parameter.c b/Src/Modules/parameter.c
index 76824cf58..ef9148d7b 100644
--- a/Src/Modules/parameter.c
+++ b/Src/Modules/parameter.c
@@ -1552,7 +1552,7 @@ setpmnameddirs(Param pm, HashTable ht)
}
}
- /* The INTERACTIVE stuff ensures that the dirs are not immediatly removed
+ /* The INTERACTIVE stuff ensures that the dirs are not immediately removed
* when the sub-pms are deleted. */
i = opts[INTERACTIVE];
diff --git a/Src/Zle/comp.h b/Src/Zle/comp.h
index 743a2e3ac..2e3249b52 100644
--- a/Src/Zle/comp.h
+++ b/Src/Zle/comp.h
@@ -35,7 +35,7 @@ typedef struct cexpl *Cexpl;
typedef struct cmgroup *Cmgroup;
typedef struct cmatch *Cmatch;
-/* This is for explantion strings. */
+/* This is for explanation strings. */
struct cexpl {
int always; /* display even without matches */
@@ -126,8 +126,8 @@ struct cmatch {
#define CMF_FILE (1<< 0) /* this is a file */
#define CMF_REMOVE (1<< 1) /* remove the suffix */
-#define CMF_ISPAR (1<< 2) /* is paramter expansion */
-#define CMF_PARBR (1<< 3) /* paramter expansion with a brace */
+#define CMF_ISPAR (1<< 2) /* is parameter expansion */
+#define CMF_PARBR (1<< 3) /* parameter expansion with a brace */
#define CMF_PARNEST (1<< 4) /* nested parameter expansion */
#define CMF_NOLIST (1<< 5) /* should not be listed */
#define CMF_DISPLINE (1<< 6) /* display strings one per line */
diff --git a/Src/Zle/compcore.c b/Src/Zle/compcore.c
index 9b8545360..7e3badc57 100644
--- a/Src/Zle/compcore.c
+++ b/Src/Zle/compcore.c
@@ -1492,7 +1492,7 @@ set_comp_sep(void)
* are specially handled (but currently only if RCQUOTES is not
* set, which isn't necessarily correct if the quotes were typed by
* the user).
- * osq: c.f. odq, taking account of Snull's and embeded "'"'s.
+ * osq: c.f. odq, taking account of Snull's and embedded "'"'s.
* qttype: type of quotes using standard QT_* definitions.
* lsq: when quoting is single quotes (QT_SINGLE), counts the offset
* adjustment needed in the word being examined in the lexer loop.
diff --git a/Src/Zle/compctl.c b/Src/Zle/compctl.c
index 1dcec387d..08355d1b9 100644
--- a/Src/Zle/compctl.c
+++ b/Src/Zle/compctl.c
@@ -1726,7 +1726,7 @@ static Patprog patcomp, filecomp;
* lppre/lpsuf -- the path prefix/suffix, unexpanded *
* fpre/fsuf -- prefix/suffix of the pathname component the cursor is in *
* prpre -- ppre in expanded form usable for opendir *
- * qipre, qisuf-- ingnored quoted string *
+ * qipre, qisuf-- ignored quoted string *
* *
* The integer variables hold the lengths of lpre, lsuf, rpre, rsuf, *
* fpre, fsuf, lppre, and lpsuf. noreal is non-zero if we have rpre/rsuf. */
diff --git a/Src/Zle/complete.c b/Src/Zle/complete.c
index 7d9751fa6..7beb6d847 100644
--- a/Src/Zle/complete.c
+++ b/Src/Zle/complete.c
@@ -84,7 +84,7 @@ char *compiprefix,
Param *comprpms;
/*
- * An array of Param structures for elemens of $compstate; see
+ * An array of Param structures for elements of $compstate; see
* 'compkparams' below.
*
* See CP_KEYPARAMS.
diff --git a/Src/Zle/compresult.c b/Src/Zle/compresult.c
index 05799399d..30fc60b78 100644
--- a/Src/Zle/compresult.c
+++ b/Src/Zle/compresult.c
@@ -827,7 +827,7 @@ do_ambiguous(void)
* if the completion is completely ambiguous') is set, and some *
* prefix was inserted, return now, bypassing the list-displaying *
* code. On the way, invalidate the list and note that we don't *
- * want to enter an AUTO_MENU imediately. */
+ * want to enter an AUTO_MENU immediately. */
if ((uselist == 3 ||
(!uselist && isset(BASHAUTOLIST) && isset(LISTAMBIGUOUS))) &&
la && iforcemenu != -1) {
diff --git a/Src/Zle/computil.c b/Src/Zle/computil.c
index cb1c01042..90db8b4b8 100644
--- a/Src/Zle/computil.c
+++ b/Src/Zle/computil.c
@@ -967,7 +967,7 @@ struct caarg {
#define CAA_RARGS 4
#define CAA_RREST 5
-/* The cache of parsed descriptons. */
+/* The cache of parsed descriptions. */
#define MAX_CACACHE 8
static Cadef cadef_cache[MAX_CACACHE];
diff --git a/Src/Zle/zle_keymap.c b/Src/Zle/zle_keymap.c
index a5cf1011b..d13aed594 100644
--- a/Src/Zle/zle_keymap.c
+++ b/Src/Zle/zle_keymap.c
@@ -55,7 +55,7 @@ struct keymapname {
HashNode next; /* next in the hash chain */
char *nam; /* name of the keymap */
int flags; /* various flags (see below) */
- Keymap keymap; /* the keymap itsef */
+ Keymap keymap; /* the keymap itself */
};
/* Can't be deleted (.safe) */
diff --git a/Src/Zle/zle_main.c b/Src/Zle/zle_main.c
index 22cb21be3..be68f4722 100644
--- a/Src/Zle/zle_main.c
+++ b/Src/Zle/zle_main.c
@@ -893,7 +893,7 @@ getbyte(long do_keytmout, int *timeout, int full)
break;
if (r == 0) {
/* The test for IGNOREEOF was added to make zsh ignore ^Ds
- that were typed while commands are running. Unfortuantely
+ that were typed while commands are running. Unfortunately
this caused trouble under at least one system (SunOS 4.1).
Here shells that lost their xterm (e.g. if it was killed
with -9) didn't fail to read from the terminal but instead
diff --git a/Src/Zle/zle_refresh.c b/Src/Zle/zle_refresh.c
index 9d46378cf..7b8593dec 100644
--- a/Src/Zle/zle_refresh.c
+++ b/Src/Zle/zle_refresh.c
@@ -388,7 +388,7 @@ zle_free_highlight(void)
/*
* Interface to the region_highlight ZLE parameter.
- * Converts betwen a format like "P32 42 underline,bold" to
+ * Converts between a format like "P32 42 underline,bold" to
* the format in the region_highlights variable. Note that
* the region_highlights variable stores the internal (point/mark)
* region in element zero.
diff --git a/Src/pattern.c b/Src/pattern.c
index 95e5a79a0..c7c2c8bea 100644
--- a/Src/pattern.c
+++ b/Src/pattern.c
@@ -2492,7 +2492,7 @@ pattryrefs(Patprog prog, char *string, int stringlen, int unmetalenin,
* Optimization: if we didn't find any Meta characters
* to begin with, we don't need to look for them now.
*
- * For patstralloc pased in, we want the unmetafied length.
+ * For patstralloc passed in, we want the unmetafied length.
*/
if (patstralloc == &patstralloc_struct &&
patstralloc->unmetalen != origlen) {
diff --git a/Src/zsh.h b/Src/zsh.h
index 657e6d8ec..89b393945 100644
--- a/Src/zsh.h
+++ b/Src/zsh.h
@@ -1254,7 +1254,7 @@ enum {
/*
* Assignment has value?
- * If the assignment is an arrray, then it certainly has a value --- we
+ * If the assignment is an array, then it certainly has a value --- we
* can only tell if there's an explicit assignment.
*/
diff --git a/Src/ztype.h b/Src/ztype.h
index ae7236774..5c85b0cd7 100644
--- a/Src/ztype.h
+++ b/Src/ztype.h
@@ -66,7 +66,7 @@
* shell initialisation.
*/
#define ZTF_INIT (0x0001) /* One-off initialisation done */
-#define ZTF_INTERACT (0x0002) /* Shell interative and reading from stdin */
+#define ZTF_INTERACT (0x0002) /* Shell interactive and reading from stdin */
#define ZTF_SP_COMMA (0x0004) /* Treat comma as a special characters */
#define ZTF_BANGCHAR (0x0008) /* Treat bangchar as a special character */
diff --git a/Test/B01cd.ztst b/Test/B01cd.ztst
index 977cbdfe5..3312f8707 100644
--- a/Test/B01cd.ztst
+++ b/Test/B01cd.ztst
@@ -53,7 +53,7 @@
# stderr.
#
# The rules for '<', '>' and '?' lines are the same: only the first
-# character is stripped (with the excpetion for '*' noted below), with
+# character is stripped (with the exception for '*' noted below), with
# subsequent whitespace being significant; lines are not subject to any
# substitution unless the `q' flag (see below) is set.
#
diff --git a/Test/D04parameter.ztst b/Test/D04parameter.ztst
index 83ac7ebf4..76f3e77a1 100644
--- a/Test/D04parameter.ztst
+++ b/Test/D04parameter.ztst
@@ -2512,7 +2512,7 @@ F:behavior, see http://austingroupbugs.net/view.php?id=888
local -a x
: <<< ${(F)x/y}
}
-0:Separation / join logic regresssion test
+0:Separation / join logic regression test
testpath=/one/two/three/four
for (( i = 0; i <= 6; ++i )); do
--
cgit v1.2.3