Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: 6-pws-2



In article <199908311238.OAA29874@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
  Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx> writes:

> > In article <9908301600.AA12634@xxxxxxxxxxxxxxxxx>,
> >   Peter Stephenson <pws@xxxxxxxxxxxxxxxxx> writes:
> > > - Personally, I prefer one single completion function for a suite of
> > >   related commands like cvs or pbm, since the accumulated clutter (and
> > >   added time to process completion files the first time) is large.  If it
> > >   stays the way it is I will change the default for function installation
> > >   to keep the subdirectories.

I think making cache file for each directory in fpath reduce start
time. Because the directory that contains many files
--- /usr/local/share/zsh/functions --- is stable in many case (except
for some zsh developpers).

> > 
> > The separation is sometimes useful for custumizations because we can
> > override each function individually. These functions behaves like `hook'.
> > I think it is useful that making hooks more easily without adding new files.
> 
> Hm. How about making it a bit like a state machine:

I feel that a state machine is the good abstraction for command line
parsing.

# I suspect that most command line structures can be represented by
# regex.

> Would that be acceptable to everyone? Can anyone think of ways to help 
> users write such state-machine functions?

Hm. I think it is reasonable to implement a state as a function.
A state transition can be represented as return from the function with
next state.
-- 
Tanaka Akira



Messages sorted by: Reverse Date, Date, Thread, Author