* Re: PATCH: change module_path to mpath(?)
1999-02-01 9:13 PATCH: change module_path to mpath(?) Sven Wischnowsky
@ 1999-02-01 9:09 ` Peter Stephenson
0 siblings, 0 replies; 3+ messages in thread
From: Peter Stephenson @ 1999-02-01 9:09 UTC (permalink / raw)
To: zsh-workers
Sven Wischnowsky wrote:
> When I was fiddling with the module stuff I said that I would like to
> change the name of the parameter `module_path' to `mapth' (to match it
^^^^^ mpath
> with `fpath' and to avoid the underscore which is quite unusual for a
> zsh-parameter).
This has been in all(?) the versions of 3.1 so far, so it's now quite
a big change. Also, if we changed it there would be something to be
said for making it more obviously zsh-specific with a z or someting.
Probably the wider zsh community needs to be asked about this. 3.1's
still in beta, but even so...
--
Peter Stephenson <pws@ibmth.df.unipi.it> Tel: +39 050 844536
WWW: http://www.ifh.de/~pws/
Dipartimento di Fisica, Via Buonarroti 2, 56127 Pisa, Italy
^ permalink raw reply [flat|nested] 3+ messages in thread
* PATCH: change module_path to mpath(?)
@ 1999-02-01 9:13 Sven Wischnowsky
1999-02-01 9:09 ` Peter Stephenson
0 siblings, 1 reply; 3+ messages in thread
From: Sven Wischnowsky @ 1999-02-01 9:13 UTC (permalink / raw)
To: zsh-workers
When I was fiddling with the module stuff I said that I would like to
change the name of the parameter `module_path' to `mapth' (to match it
with `fpath' and to avoid the underscore which is quite unusual for a
zsh-parameter).
The patch below does this. So this is an incompatible change and I'm
far from sure if you'll want to apply it. Also I'm not sure, if you
like it anyway.
Bye
Sven
diff -u os/init.c Src/init.c
--- os/init.c Sat Jan 30 21:20:19 1999
+++ Src/init.c Sat Jan 30 21:22:07 1999
@@ -515,7 +515,7 @@
watch = mkarray(NULL);
psvar = mkarray(NULL);
#ifdef DYNAMIC
- module_path = mkarray(ztrdup(MODULE_DIR));
+ mpath = mkarray(ztrdup(MODULE_DIR));
modules = newlinklist();
#endif
diff -u os/module.c Src/module.c
--- os/module.c Sat Jan 30 21:20:19 1999
+++ Src/module.c Sat Jan 30 21:22:50 1999
@@ -127,10 +127,10 @@
#ifdef DYNAMIC
-/* $module_path ($MODULE_PATH) */
+/* $mpath ($MPATH) */
/**/
-char **module_path;
+char **mpath;
/* List of modules */
@@ -345,7 +345,7 @@
}
l = strlen(name) + 1;
- for (pp = module_path; !ret && *pp; pp++) {
+ for (pp = mpath; !ret && *pp; pp++) {
if (l + (**pp ? strlen(*pp) : 1) > PATH_MAX)
continue;
sprintf(buf, "%s/%s", **pp ? *pp : ".", name);
diff -u os/params.c Src/params.c
--- os/params.c Sat Jan 30 21:20:19 1999
+++ Src/params.c Sat Jan 30 21:25:47 1999
@@ -202,8 +202,8 @@
IPDEF8("PSVAR", &psvar, "psvar", 0),
#ifdef DYNAMIC
-/* MODULE_PATH is not imported for security reasons */
-IPDEF8("MODULE_PATH", &module_path, "module_path", PM_DONTIMPORT|PM_RESTRICTED),
+/* MPATH is not imported for security reasons */
+IPDEF8("MPATH", &mpath, "mpath", PM_DONTIMPORT|PM_RESTRICTED),
#endif
#define IPDEF9F(A,B,C,D) {NULL,A,D|PM_ARRAY|PM_SPECIAL|PM_DONTIMPORT,BR((void *)B),SFN(arrvarsetfn),GFN(arrvargetfn),stdunsetfn,0,NULL,C,NULL,0}
@@ -238,7 +238,7 @@
/*TEST END*/
#ifdef DYNAMIC
-IPDEF9F("module_path", &module_path, "MODULE_PATH", PM_RESTRICTED),
+IPDEF9F("mpath", &mpath, "MPATH", PM_RESTRICTED),
#endif
IPDEF9F("path", &path, "PATH", PM_RESTRICTED),
diff -u om/compctl-examples Misc/compctl-examples
--- om/compctl-examples Sat Jan 30 21:19:41 1999
+++ Misc/compctl-examples Sat Jan 30 21:23:23 1999
@@ -52,7 +52,7 @@
compctl -x 'p[1]' - 'p[2,-1]' -l '' -- sched
compctl -x 'C[-1,[+-]o]' -o - 'c[-1,-A]' -A -- set
compctl -b -x 'w[1,-N] p[3]' -F -- zle
-compctl -s '${^module_path}/*(N:t:r)' -x \
+compctl -s '${^mpath}/*(N:t:r)' -x \
'W[1,-*(a*u|u*a)*],W[1,-*a*]p[3,-1]' -B - \
'W[1,-*u*]' -s '$(zmodload)' -- zmodload
diff -u om/new-completion-examples Misc/new-completion-examples
--- om/new-completion-examples Sat Jan 30 21:19:41 1999
+++ Misc/new-completion-examples Sat Jan 30 21:23:38 1999
@@ -517,7 +517,7 @@
elif [[ -mword 1 -*u* ]] then
complist -s '$(zmodload)'
else
- complist -s '${^module_path}/*(N:t:r)'
+ complist -s '${^mpath}/*(N:t:r)'
fi
}
diff -u od/Zsh/builtins.yo Doc/Zsh/builtins.yo
--- od/Zsh/builtins.yo Sat Jan 30 21:19:49 1999
+++ Doc/Zsh/builtins.yo Sat Jan 30 21:24:12 1999
@@ -1175,7 +1175,7 @@
tt(zmodload) prints an error message.
The var(name)d module is searched for in the same way a command is, using
-tt($module_path) instead of tt($path). If var(name) contains a `tt(/)',
+tt($mpath) instead of tt($path). If var(name) contains a `tt(/)',
it will be used as-is, and a path search will be performed otherwise.
This behaviour can be modified by the tt(PATH_DIRS) option.
cindex(PATH_DIRS, use of)
diff -u od/Zsh/params.yo Doc/Zsh/params.yo
--- od/Zsh/params.yo Sat Jan 30 21:19:50 1999
+++ Doc/Zsh/params.yo Sat Jan 30 21:24:30 1999
@@ -556,9 +556,9 @@
array can be useful, however, since setting it also sets
tt(MANPATH), and vice versa.
)
-vindex(module_path)
-vindex(MODULE_PATH)
-item(tt(module_path) <S> <Z> (tt(MODULE_PATH) <S>))(
+vindex(mpath)
+vindex(MPATH)
+item(tt(mpath) <S> <Z> (tt(MPATH) <S>))(
An array (colon-separated list)
of directories that tt(zmodload)
searches for dynamically loadable modules.
diff -u od/Zsh/restricted.yo Doc/Zsh/restricted.yo
--- od/Zsh/restricted.yo Sat Jan 30 21:19:50 1999
+++ Doc/Zsh/restricted.yo Sat Jan 30 21:24:51 1999
@@ -13,8 +13,8 @@
startitemize()
itemiz(changing directories with the tt(cd) builtin)
-itemiz(changing or unsetting the tt(PATH), tt(path), tt(MODULE_PATH),
-tt(module_path), tt(SHELL), tt(HISTFILE), tt(HISTSIZE), tt(GID), tt(EGID),
+itemiz(changing or unsetting the tt(PATH), tt(path), tt(MPATH),
+tt(mpath), tt(SHELL), tt(HISTFILE), tt(HISTSIZE), tt(GID), tt(EGID),
tt(UID), tt(EUID), tt(USERNAME), tt(LD_LIBRARY_PATH),
tt(LD_AOUT_LIBRARY_PATH), tt(LD_PRELOAD) and tt(LD_AOUT_PRELOAD)
parameters)
--
Sven Wischnowsky wischnow@informatik.hu-berlin.de
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: PATCH: change module_path to mpath(?)
@ 1999-02-01 9:31 Sven Wischnowsky
0 siblings, 0 replies; 3+ messages in thread
From: Sven Wischnowsky @ 1999-02-01 9:31 UTC (permalink / raw)
To: zsh-workers
Peter Stephenson wrote:
> Sven Wischnowsky wrote:
> > When I was fiddling with the module stuff I said that I would like to
> > change the name of the parameter `module_path' to `mapth' (to match it
> ^^^^^ mpath
> > with `fpath' and to avoid the underscore which is quite unusual for a
> > zsh-parameter).
>
> This has been in all(?) the versions of 3.1 so far, so it's now quite
> a big change. Also, if we changed it there would be something to be
> said for making it more obviously zsh-specific with a z or someting.
> Probably the wider zsh community needs to be asked about this. 3.1's
> still in beta, but even so...
That's why I was asking... (and warning ;-)
Bye
Sven
--
Sven Wischnowsky wischnow@informatik.hu-berlin.de
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~1999-02-01 9:31 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-02-01 9:13 PATCH: change module_path to mpath(?) Sven Wischnowsky
1999-02-01 9:09 ` Peter Stephenson
1999-02-01 9:31 Sven Wischnowsky
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).