/[emacs]/emacs/man/eshell.texi
ViewVC logotype

Diff of /emacs/man/eshell.texi

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.12 by gerd, Thu Apr 19 15:10:31 2001 UTC revision 1.12.16.1 by miles, Fri Apr 4 06:20:47 2003 UTC
# Line 1  Line 1 
1  \input texinfo  @c -*-texinfo-*-  \input texinfo  @c -*-texinfo-*-
   
2  @c "@(#)$Name$:$Id$"  @c "@(#)$Name$:$Id$"
   
 @c Documentation for Eshell: The Emacs Shell.  
 @c Copyright (C) 1999, 2000  Free Software Foundation, Inc.  
   
 @c This file is part of GNU Emacs  
   
 @c GNU Emacs is free software; you can redistribute it and/or modify it  
 @c under the terms of the GNU General Public License as published by the  
 @c Free Software Foundation; either version 2 of the License, or (at  
 @c your option) any later version.  
   
 @c GNU Emacs is distributed in the hope that it will be useful, but  
 @c WITHOUT ANY WARRANTY; without even the implied warraonty of  
 @c MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU  
 @c General Public License for more details.  
   
 @c You should have received a copy of the GNU General Public License  
 @c along with Eshell; see the file COPYING.  If not, write to the Free  
 @c Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  
   
3  @c %**start of header  @c %**start of header
4  @setfilename ../info/eshell  @setfilename ../info/eshell
5  @settitle Eshell: The Emacs Shell  @settitle Eshell: The Emacs Shell
6    @synindex vr fn
7  @c %**end of header  @c %**end of header
8    
9  @dircategory Emacs  @copying
10  @direntry  This manual is for Eshell, the Emacs shell.
 * Eshell: (eshell).     A command shell implemented in Emacs Lisp.  
 @end direntry  
 @setchapternewpage on  
       
 @ifinfo  
 Copyright @copyright{} 1999, 2000, 2001  Free Software Foundation, Inc.  
11    
12    Copyright @copyright{} 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
13    
14    @quotation
15  Permission is granted to copy, distribute and/or modify this document  Permission is granted to copy, distribute and/or modify this document
16  under the terms of the GNU Free Documentation License, Version 1.1 or  under the terms of the GNU Free Documentation License, Version 1.1 or
17  any later version published by the Free Software Foundation; with no  any later version published by the Free Software Foundation; with no
# Line 51  This document is part of a collection di Line 28  This document is part of a collection di
28  Documentation License.  If you want to distribute this document  Documentation License.  If you want to distribute this document
29  separately from the collection, you can do so by adding a copy of the  separately from the collection, you can do so by adding a copy of the
30  license to the document, as described in section 6 of the license.  license to the document, as described in section 6 of the license.
31  @end ifinfo  @end quotation
32    @end copying
33    
34    @dircategory Emacs
35    @direntry
36    * Eshell: (eshell).     A command shell implemented in Emacs Lisp.
37    @end direntry
38    
39    @setchapternewpage on
40    
 @synindex vr fn  
 @c The titlepage section does not appear in the Info file.  
41  @titlepage  @titlepage
42  @sp 4  @sp 4
43  @c The title is printed in a large font.  @c The title is printed in a large font.
# Line 72  license to the document, as described in Line 55  license to the document, as described in
55  @center John Wiegley  @center John Wiegley
56  @c -date-  @c -date-
57    
 @c  The following two commands start the copyright page for the printed  
 @c  manual.  This will not appear in the Info file.  
58  @page  @page
59  @vskip 0pt plus 1filll  @vskip 0pt plus 1filll
60  Copyright @copyright{} 1999, 2000, 2001  Free Software Foundation, Inc.  @insertcopying
   
 Permission is granted to copy, distribute and/or modify this document  
 under the terms of the GNU Free Documentation License, Version 1.1 or  
 any later version published by the Free Software Foundation; with no  
 Invariant Sections, with the Front-Cover texts being ``A GNU  
 Manual'', and with the Back-Cover Texts as in (a) below.  A copy of the  
 license is included in the section entitled ``GNU Free Documentation  
 License'' in the Emacs manual.  
   
 (a) The FSF's Back-Cover Text is: ``You have freedom to copy and modify  
 this GNU Manual, like GNU software.  Copies published by the Free  
 Software Foundation raise funds for GNU development.''  
   
 This document is part of a collection distributed under the GNU Free  
 Documentation License.  If you want to distribute this document  
 separately from the collection, you can do so by adding a copy of the  
 license to the document, as described in section 6 of the license.  
61  @end titlepage  @end titlepage
62    
63  @contents  @contents
# Line 102  license to the document, as described in Line 66  license to the document, as described in
66  @c                   The real text starts here  @c                   The real text starts here
67  @c ================================================================  @c ================================================================
68    
69    @ifnottex
70  @node Top, What is Eshell?, (dir), (dir)  @node Top, What is Eshell?, (dir), (dir)
 @ifinfo  
71  @top Eshell  @top Eshell
72    
73  This manual documents Eshell, a shell-like command interpretor  This manual documents Eshell, a shell-like command interpretor
# Line 113  replacement for command shells such as @ Line 77  replacement for command shells such as @
77  @command{rc}, or @command{4dos}; since Emacs itself is capable of  @command{rc}, or @command{4dos}; since Emacs itself is capable of
78  handling the sort of tasks accomplished by those tools.  handling the sort of tasks accomplished by those tools.
79  @c This manual is updated to release 2.4 of Eshell.  @c This manual is updated to release 2.4 of Eshell.
80  @end ifinfo  @end ifnottex
81    
82  @menu  @menu
83  * What is Eshell?::             A brief introduction to the Emacs Shell.  * What is Eshell?::             A brief introduction to the Emacs Shell.
84  * Installation::                For users of Emacs 20 and XEmacs.  * Installation::                For users of Emacs 20 and XEmacs.
85  * Command basics::              The basics of command usage.      * Command basics::              The basics of command usage.
86  * Commands::                      * Commands::
87  * Arguments::                    * Arguments::
88  * Input/Output::                  * Input/Output::
89  * Process control::              * Process control::
90  * Extension modules::            * Extension modules::
91  * Extras and Goodies::            * Extras and Goodies::
92  * Bugs and ideas::              Known problems, and future ideas.  * Bugs and ideas::              Known problems, and future ideas.
93  * Concept Index::                * Concept Index::
94  * Function and Variable Index::    * Function and Variable Index::
95  * Key Index::                    * Key Index::
96  @end menu  @end menu
97    
98  @node What is Eshell?, Installation, Top, Top  @node What is Eshell?
99  @chapter What is Eshell?  @chapter What is Eshell?
100  @cindex what is Eshell?  @cindex what is Eshell?
101  @cindex Eshell, what it is  @cindex Eshell, what it is
# Line 189  As of Emacs 21, Eshell is part of the st Line 153  As of Emacs 21, Eshell is part of the st
153  * Contributors to Eshell::      People who have helped out!  * Contributors to Eshell::      People who have helped out!
154  @end menu  @end menu
155    
156  @node Contributors to Eshell,  , What is Eshell?, What is Eshell?  @node Contributors to Eshell
157  @section Contributors to Eshell  @section Contributors to Eshell
158  @cindex contributors  @cindex contributors
159  @cindex authors  @cindex authors
# Line 229  Apart from these, a lot of people have s Line 193  Apart from these, a lot of people have s
193  requests, bug reports and encouragement.  Thanks a lot!  Without you  requests, bug reports and encouragement.  Thanks a lot!  Without you
194  there would be no new releases of Eshell.  there would be no new releases of Eshell.
195    
196  @node Installation, Command basics, What is Eshell?, Top  @node Installation
197  @chapter Installation  @chapter Installation
198  @cindex installation  @cindex installation
199    
200  As mentioned above, Eshell comes preinstalled as of Emacs 21.  If you're  As mentioned above, Eshell comes preinstalled as of Emacs 21.  If you're
201  using Emacs 20.4 or later, or XEmacs 21, you can download the most  using Emacs 20.4 or later, or XEmacs 21, you can download the most
202  recent version of Eshell from  recent version of Eshell from
203  @url{http://www.gci-net.com/users/j/johnw/Emacs/eshell.tar.gz}.  @url{http://www.gci-net.com/users/j/johnw/Emacs/packages/eshell.tar.gz}.
204    
205  However, if you are using Emacs 21, you may skip this section.  However, if you are using Emacs 21, you may skip this section.
206    
# Line 419  you can use.  For other printers, use a Line 383  you can use.  For other printers, use a
383  e.g., @code{dvilj4} for LaserJet-compatible printers.  e.g., @code{dvilj4} for LaserJet-compatible printers.
384  @end enumerate  @end enumerate
385    
386  @node Command basics, Commands, Installation, Top  @node Command basics
387  @chapter Basic overview  @chapter Basic overview
388    
389  A command shell is a means of entering verbally-formed commands.  This  A command shell is a means of entering verbally-formed commands.  This
# Line 433  things. Line 397  things.
397  * Command arguments::           Some verbs require arguments.  * Command arguments::           Some verbs require arguments.
398  @end menu  @end menu
399    
400  @node Commands verbs, Command arguments, Command basics, Command basics  @node Commands verbs
401  @section Commands verbs  @section Commands verbs
402    
403  Commands are expressed using @dfn{script}, a special shorthand language  Commands are expressed using @dfn{script}, a special shorthand language
# Line 476  textual arguments, numerical arguments-- Line 440  textual arguments, numerical arguments--
440  Distinguishing these different types of arguments requires special  Distinguishing these different types of arguments requires special
441  typing, for the computer to know exactly what you mean.  typing, for the computer to know exactly what you mean.
442    
443  @node Command arguments,  , Commands verbs, Command basics  @node Command arguments
444  @section Command arguments  @section Command arguments
445    
446  Eshell recognizes several different kinds of command arguments:  Eshell recognizes several different kinds of command arguments:
# Line 511  with Eshell as a basic command invocatio Line 475  with Eshell as a basic command invocatio
475  commands on your system; then come back when it all sits more familiarly  commands on your system; then come back when it all sits more familiarly
476  on your mind.  Have fun!  on your mind.  Have fun!
477    
478  @node Commands, Arguments, Command basics, Top  @node Commands
479  @chapter Commands  @chapter Commands
480    
481  @menu  @menu
482  * Invocation::                    * Invocation::
483  * Completion::                    * Completion::
484  * Aliases::                      * Aliases::
485  * History::                      * History::
486  * Scripts::                      * Scripts::
487    * Built-ins::
488  @end menu  @end menu
489    
490  Essentially, a command shell is all about invoking commands---and  Essentially, a command shell is all about invoking commands---and
491  everything that entails.  So understanding how Eshell invokes commands  everything that entails.  So understanding how Eshell invokes commands
492  is the key to comprehending how it all works.  is the key to comprehending how it all works.
493    
494  @node Invocation, Completion, Commands, Commands  @node Invocation
495  @section Invocation  @section Invocation
496    
497  Unlike regular system shells, Eshell never invokes kernel functions  Unlike regular system shells, Eshell never invokes kernel functions
# Line 542  command, follows these steps: Line 507  command, follows these steps:
507    
508  @enumerate  @enumerate
509  @item Parse the command string into separate arguments.  @item Parse the command string into separate arguments.
510  @item  @item
511  @end enumerate  @end enumerate
512    
513  @node Completion, Aliases, Invocation, Commands  @node Completion
514  @section Completion  @section Completion
515    
516  @node Aliases, History, Completion, Commands  @node Aliases
517  @section Aliases  @section Aliases
518    
519  @node History, Scripts, Aliases, Commands  @node History
520  @section History  @section History
521    
522  @node Scripts,  , History, Commands  Eshell knows a few built-in variables:
523    
524    @table @code
525    
526    @item $+
527    @vindex $+
528    This variable always contains the current working directory.
529    
530    @item $-
531    @vindex $-
532    This variable always contains the previous working directory (the
533    current working directory from before the last @code{cd} command).
534    
535    @end table
536    
537    @node Scripts
538  @section Scripts  @section Scripts
539    
540    
541  @node Arguments, Input/Output, Commands, Top  @node Built-ins
542    @section Built-in commands
543    
544    Here is a list of built-in commands that Eshell knows about:
545    
546    @table @code
547    
548    @item cd
549    @findex cd
550    This command changes the current working directory.  Usually, it is
551    invoked as @samp{cd foo} where @file{foo} is the new working
552    directory.  But @code{cd} knows about a few special arguments:
553    
554    When it receives no argument at all, it changes to the home directory.
555    
556    Giving the command @samp{cd -} changes back to the previous working
557    directory (this is the same as @samp{cd $-}).
558    
559    The command @samp{cd =} shows the directory stack.  Each line is
560    numbered.
561    
562    With @samp{cd =foo}, Eshell searches the directory stack for a
563    directory matching the regular expression @samp{foo} and changes to
564    that directory.
565    
566    With @samp{cd -42}, you can access the directory stack by number.
567    
568    @end table
569    
570    
571    @node Arguments
572  @chapter Arguments  @chapter Arguments
573    
574  @menu  @menu
575  * The Parser::                    * The Parser::
576  * Variables::                    * Variables::
577  * Substitution::                  * Substitution::
578  * Globbing::                      * Globbing::
579  * Predicates::                    * Predicates::
580  @end menu  @end menu
581    
582  @node The Parser, Variables, Arguments, Arguments  @node The Parser
583  @section The Parser  @section The Parser
584    
585  @node Variables, Substitution, The Parser, Arguments  @node Variables
586  @section Variables  @section Variables
587    
588  @node Substitution, Globbing, Variables, Arguments  @node Substitution
589  @section Substitution  @section Substitution
590    
591  @node Globbing, Predicates, Substitution, Arguments  @node Globbing
592  @section Globbing  @section Globbing
593    
594  @node Predicates,  , Globbing, Arguments  @node Predicates
595  @section Predicates  @section Predicates
596    
597    
598  @node Input/Output, Process control, Arguments, Top  @node Input/Output
599  @chapter Input/Output  @chapter Input/Output
600    
601  @node Process control, Extension modules, Input/Output, Top  @node Process control
602  @chapter Process control  @chapter Process control
603    
604    
605  @node Extension modules, Extras and Goodies, Process control, Top  @node Extension modules
606  @chapter Extension modules  @chapter Extension modules
607    
608  @menu  @menu
609  * Writing a module::              * Writing a module::
610  * Module testing::                * Module testing::
611  * Directory handling::            * Directory handling::
612  * Key rebinding::                * Key rebinding::
613  * Smart scrolling::              * Smart scrolling::
614  * Terminal emulation::            * Terminal emulation::
615  * Built-in UNIX commands::        * Built-in UNIX commands::
616  @end menu  @end menu
617    
618  @node Writing a module, Module testing, Extension modules, Extension modules  @node Writing a module
619  @section Writing a module  @section Writing a module
620    
621  @node Module testing, Directory handling, Writing a module, Extension modules  @node Module testing
622  @section Module testing  @section Module testing
623    
624  @node Directory handling, Key rebinding, Module testing, Extension modules  @node Directory handling
625  @section Directory handling  @section Directory handling
626    
627  @node Key rebinding, Smart scrolling, Directory handling, Extension modules  @node Key rebinding
628  @section Key rebinding  @section Key rebinding
629    
630  @node Smart scrolling, Terminal emulation, Key rebinding, Extension modules  @node Smart scrolling
631  @section Smart scrolling  @section Smart scrolling
632    
633  @node Terminal emulation, Built-in UNIX commands, Smart scrolling, Extension modules  @node Terminal emulation
634  @section Terminal emulation  @section Terminal emulation
635    
636  @node Built-in UNIX commands,  , Terminal emulation, Extension modules  @node Built-in UNIX commands
637  @section Built-in UNIX commands  @section Built-in UNIX commands
638    
639    
640  @node Extras and Goodies, Bugs and ideas, Extension modules, Top  @node Extras and Goodies
641  @chapter Extras and Goodies  @chapter Extras and Goodies
642    
643  @node Bugs and ideas, Concept Index, Extras and Goodies, Top  @node Bugs and ideas
644  @chapter Bugs and ideas  @chapter Bugs and ideas
645  @cindex reporting bugs and ideas  @cindex reporting bugs and ideas
646  @cindex bugs, how to report them  @cindex bugs, how to report them
# Line 649  extensions to this package, I would like Line 659  extensions to this package, I would like
659  find this package useful!  find this package useful!
660    
661  @menu  @menu
662  * Known problems::                * Known problems::
663  @end menu  @end menu
664    
665  @node Known problems,  , Bugs and ideas, Bugs and ideas  @node Known problems
666  @section Known problems  @section Known problems
667  @cindex known bugs  @cindex known bugs
668  @cindex bugs, known  @cindex bugs, known
# Line 716  scrolls back. Line 726  scrolls back.
726    
727  @item Using C-p and C-n with rebind gets into a locked state  @item Using C-p and C-n with rebind gets into a locked state
728    
729  This happened a few times in Emacs 21, but has been unreproducable  This happened a few times in Emacs 21, but has been unreproducible
730  since.  since.
731    
732  @item If an interactive process is currently running, @kbd{M-!} doesn't work  @item If an interactive process is currently running, @kbd{M-!} doesn't work
# Line 962  from @samp{!:1*}. Line 972  from @samp{!:1*}.
972    
973  This would allow for an ``output translators'', that take a function to  This would allow for an ``output translators'', that take a function to
974  modify output with, and a target.  Devise a syntax that works well with  modify output with, and a target.  Devise a syntax that works well with
975  pipes, and can accomodate multiple functions (i.e., @samp{>'(upcase  pipes, and can accommodate multiple functions (i.e., @samp{>'(upcase
976  regexp-quote)} or @samp{>'upcase}).  regexp-quote)} or @samp{>'upcase}).
977    
978  @item Allow Eshell to read/write to/from standard input and output  @item Allow Eshell to read/write to/from standard input and output
# Line 1081  perform this on-thy-fly rewriting. Line 1091  perform this on-thy-fly rewriting.
1091  @item Write an alias for @command{less} that brings up a @code{view-mode} buffer  @item Write an alias for @command{less} that brings up a @code{view-mode} buffer
1092    
1093  Such that the user can press @key{SPC} and @key{DEL}, and then @key{q}  Such that the user can press @key{SPC} and @key{DEL}, and then @key{q}
1094  to return to Eshell.  It would be equivalent to:  to return to Eshell.  It would be equivalent to:
1095  @samp{X > #<buffer Y>; view-buffer #<buffer Y>}.  @samp{X > #<buffer Y>; view-buffer #<buffer Y>}.
1096    
1097  @item Make @code{eshell-mode} as much a full citizen as @code{shell-mode}  @item Make @code{eshell-mode} as much a full citizen as @code{shell-mode}
# Line 1103  Since it keeps the cursor up where the c Line 1113  Since it keeps the cursor up where the c
1113    
1114  @end table  @end table
1115    
1116  @node Concept Index, Function and Variable Index, Bugs and ideas, Top  @node Concept Index
1117  @unnumbered Concept Index  @unnumbered Concept Index
1118    
1119  @printindex cp  @printindex cp
1120    
1121  @node Function and Variable Index, Key Index, Concept Index, Top  @node Function and Variable Index
1122  @unnumbered Function and Variable Index  @unnumbered Function and Variable Index
1123    
1124  @printindex fn  @printindex fn
1125    
1126  @node Key Index,  , Function and Variable Index, Top  @node Key Index
1127  @unnumbered Key Index  @unnumbered Key Index
1128    
1129  @printindex ky  @printindex ky

Legend:
Removed from v.1.12  
changed lines
  Added in v.1.12.16.1

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26