Mercurial > hg > Members > kono > nitros9-code
annotate docs/nitros9guide/shell.refentry @ 2111:6ccd6e25a441
Fixed issues with pshs and puls of 6309 registers -- a nono!
author | boisy |
---|---|
date | Thu, 26 Jul 2007 16:41:45 +0000 |
parents | bc28c3bc3769 |
children |
rev | line source |
---|---|
138 | 1 <refentry id="shell"> |
2 <refnamediv> | |
3 <refname>SHELL</refname> | |
4 <refpurpose>OS-9 Command Interpreter</refpurpose> | |
5 </refnamediv> | |
6 | |
7 <refsynopsisdiv> | |
8 <cmdsynopsis> | |
1093 | 9 <command>shell</command> |
975
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
10 <arg choice="plain"><replaceable>arglist</replaceable></arg> |
138 | 11 </cmdsynopsis> |
12 </refsynopsisdiv> | |
13 | |
14 <refsect1><title>Description</title> | |
15 <para> | |
1053
b5ff125a1d60
Since this book was only typeset in fixed width, single-font, they used
roug
parents:
975
diff
changeset
|
16 The <command>shell</command> is OS-9's command interpreter program. It reads data from |
138 | 17 its standard input path (the keyboard or a file), and interprets the |
18 data as a sequence of commands. - The basic function of the shell is | |
19 to initiate and control execution of other OS-9 programs. | |
20 </para> | |
21 <para> | |
22 The shell reads and interprets one text line at a time from the | |
23 standard input path. After interpretation of each line it reads | |
24 another until an end-of-file condition occurs, at which time it | |
25 terminates itself. A special case is when the shell is called from | |
26 another program, in which case it will take the parameter area (rest | |
27 of the command line) as its first line of input. If this command | |
28 line consists of "built in" commands only, more lines will be read | |
29 and processed; otherwise control will return to the calling program | |
30 after the single command line is processed. | |
31 </para> | |
32 <para> | |
33 The rest of this description is a technical specification of the | |
1053
b5ff125a1d60
Since this book was only typeset in fixed width, single-font, they used
roug
parents:
975
diff
changeset
|
34 shell syntax. Use of the <command>shell</command> is described fully in Chapters 2 |
138 | 35 and 4 of this manual. |
36 </para> | |
37 </refsect1> | |
38 <refsect1><title>Shell Input Line Formal Syntax</title> | |
39 <synopsis> | |
975
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
40 <replaceable>pgm line</replaceable> := <replaceable>pgm</replaceable> {<replaceable>pgm</replaceable>} |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
41 <replaceable>pgm</replaceable> := [<replaceable>params</replaceable>] [ <replaceable>name</replaceable> [<replaceable>modif</replaceable>] [<replaceable>pgm params</replaceable>] [<replaceable>modif</replaceable>] ] [<replaceable>sep</replaceable>] |
138 | 42 |
43 Program Specifications | |
44 | |
975
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
45 <replaceable>name</replaceable> := <replaceable>module name</replaceable> |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
46 := <replaceable>pathlist</replaceable> |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
47 := ( <replaceable>pgm list</replaceable> ) |
138 | 48 |
49 Parameters | |
50 | |
975
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
51 <replaceable>params</replaceable>:= <replaceable>param</replaceable> { <replaceable>delim</replaceable> <replaceable>param</replaceable> } |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
52 <replaceable>delim</replaceable> := space or comma characters |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
53 <replaceable>param</replaceable> := ex <replaceable>name</replaceable> [<replaceable>modif</replaceable>] chain to program specified |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
54 := chd <replaceable>pathlist</replaceable> change working directory |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
55 := kill <replaceable>procID</replaceable> send abort signal to process |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
56 := setpr<replaceable>procID</replaceable> <replaceable>pty</replaceable> change process priority |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
57 := chx <replaceable>pathlist</replaceable> change execution directory |
138 | 58 := w wait for any process to die |
59 := p turn "OS9:" prompting on | |
60 := -p turn prompting off | |
61 := t echo input lines to std output | |
62 := -t don't echo input lines | |
63 := -x dont abort on error | |
64 := x abort on error | |
975
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
65 := * <replaceable>text</replaceable> comment line: not processed |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
66 <replaceable>sep</replaceable> := ; sequential execution separator |
138 | 67 := & concurrent execution separator |
68 := ! pipeline separator | |
975
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
69 := <replaceable>cr</replaceable> end-of-line (sequential execution separator) |
138 | 70 |
71 | |
72 Modifiers | |
73 | |
975
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
74 <replaceable>modif</replaceable> := <replaceable>mod</replaceable> { <replaceable>delim</replaceable> <replaceable>mod</replaceable> } |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
75 <replaceable>mod</replaceable> := < <replaceable>pathlist</replaceable> redirect standard input |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
76 := > <replaceable>pathlist</replaceable> redirect standard output |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
77 := >> <replaceable>pathlist</replaceable> redirect standard error output |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
78 := # <replaceable>integer</replaceable> set process memory size in pages |
c565a4700689
The entitity replstart was replaced with <replaceable>
roug
parents:
138
diff
changeset
|
79 := # <replaceable>integer</replaceable> K set program memory size in 1K increments |
138 | 80 </synopsis> |
1148 | 81 <!-- |
82 .. A new way to describe the syntax .. | |
83 <productionset><title>Program Line</title> | |
84 <production id="shell.line"> | |
85 <lhs>pgm line</lhs> | |
86 <rhs><nonterminal def="shell.pgm">pgm</nonterminal> | |
87 {<nonterminal def="shell.pgm">pgm</nonterminal>} | |
88 </rhs> | |
89 </production> | |
90 <production id="shell.pgm"> | |
91 <lhs>pgm</lhs> | |
92 <rhs>[<nonterminal def="shell.params">params</nonterminal>] | |
93 [ <nonterminal def="shell.name">name</nonterminal> | |
94 [<nonterminal def="shell.modif">modif</nonterminal>] | |
95 [<nonterminal def="shell.pgmparams">pgm params</nonterminal>] | |
96 [<nonterminal def="shell.modif">modif</nonterminal>] ] | |
97 [<nonterminal def="shell.sep">sep</nonterminal>] | |
98 </rhs> | |
99 </production> | |
100 </productionset> | |
101 <productionset><title>Program Specifications</title> | |
102 <production id="shell.name"> | |
103 <lhs>name</lhs> | |
104 <rhs> | |
105 <nonterminal def="shell.name">module name</nonterminal> | |
106 | <nonterminal def="shell.pathlist">pathlist</nonterminal> | |
107 |( <nonterminal def="shell.pgmlist">pgm list</nonterminal> ) | |
108 </rhs> | |
109 </production> | |
110 </productionset> | |
111 <productionset><title>Parameters</title> | |
112 <production id="shell.params"> | |
113 <lhs>params</lhs> | |
114 <rhs><nonterminal def="shell.param">param</nonterminal> | |
115 { <nonterminal def="shell.delim">delim</nonterminal> | |
116 <nonterminal def="shell.param">param</nonterminal> } | |
117 </rhs> | |
118 </production> | |
119 <production id="shell.delim"> | |
120 <lhs>delim</lhs> | |
121 <rhs>space or comma characters</rhs> | |
122 </production> | |
123 <production id="shell.param"> | |
124 <lhs>param</lhs> | |
125 <rhs>ex <nonterminal def="shell.name">name</nonterminal> | |
126 [<nonterminal def="shell.modif">modif</nonterminal>] | |
127 <lineannotation>chain to program specified</lineannotation> | |
128 <sbr/> | |
129 chd <nonterminal def="shell.name">pathlist</nonterminal> | |
130 <lineannotation>change working directory</lineannotation> | |
131 </rhs> | |
132 </production> | |
133 | |
134 | |
135 | |
136 | |
137 <production id="shell.param"> | |
138 <lhs>param</lhs> | |
139 <rhs>space or comma characters</rhs> | |
140 </production> | |
141 </productionset> | |
142 --> | |
138 | 143 </refsect1> |
144 </refentry> |