home *** CD-ROM | disk | FTP | other *** search
-
-
-
- ==================================================
-
-
- @(#) OKAMI SHELL VERSION 1.5 - ENGLISH INSTRUCTIONS
-
-
- ==================================================
- Sep 19th, 1992
-
-
-
-
- The Okami Shell is a Unix-like CLI for the Atari ST. It should run on
- any ST. 1 MB and harddisk are recommended, modem and mouse are optional.
- It will run on all screen resolutions, although some commands require
- lines to be at least 80 characters wide. MiNT is supported.
-
- The Okami Shell resembles the Unix Bourne Shell (/bin/sh) and in
- particular the AIX Shell found on the IBM RT 6150 computer system.
- Although not completely compatible to the original, it gives the user
- much of the comfort of the Unix interface.
-
- The Okami Shell has some 100 built-in (internal) commands. They are all
- listed in the file `help' which can be viewed with the command "help".
- Pressing the HELP key after entering a command will display the
- appropriate chapter from the file named by the shell variable HELPFILE.
- (No english version yet, sorry)
-
-
- SUPPORT
-
- The Okami Shell is public domain. Everybody may possess, use, and
- distribute it without profit. There are no shareware fees, although
- donations are greately appreciated.
- Hints and suggestions are always welcome. So are all errors you found in
- the program and the documentation (including language errors :)). Send
- them to
-
- Wolfram Roesler
- Augustastr. 44-46
- W-5100 Aachen
- Germany
-
-
- or via EMail:
- wr@bara.oche.de
- or via Mausnet gateway to: Wolfram_Roesler@ac2.maus.de
-
-
-
- INSTALLATION
-
- The shell doesn't require any installation except copying the okami
- folder onto the hard disk or a diskette.
- After starting, the shell executes the file `profile' in the current
- directory as a shell script. So, you should tailor this file to suit
- your needs.
-
-
-
- STARTING
-
- The shell can be started from the desktop by double-clicking on sh.ttp .
- Any commands entered on the command line will be executed by the shell.
- They may be introduced by `-c' which is ignored. Having executed these
- commands, the shell will exit.
- When a single `-' is passed as a parameter, the shell will execute the
- file `profile' in the current directory. If the environment variable
- OKSH_PROFILE is set to the name of a file, then that file will be
- executed as a profile.
- It is recommended to start the shell with a `-' parameter using the
- supplied msh.prg since there will be trouble running GEM programs from
- the shell if it has been started as a ttp from desktop.
-
- The shell installs itself in the _shell_p vector from where it can be
- called by successive programs using the C library's system() function.
-
-
-
- ENDING
-
- The shell can be terminated by entering `exit' or pressing Ctrl-D.
-
-
-
- RUNNING PROGRAMS
-
- All executable programs can be started by the shell. However, some
- shell variables have to be set:
-
- XEXT must contain the extenders of all files that are to
- be considered binaries. The default is
- ".prg,.tos,.ttp,.app".
- GEXT must contain the extenders of all files that are to
- be started as GEM programs. The default is ".prg".
- PATH must contain all directories (including drive id) that
- are to be searched for executable files.
-
- So, if XEXT is ".prg,.ttp" and PATH is "c:/bin,$HOME/bin", after typing
- "cmd", the shell will seek the files c:/bin/cmd.prg, c:/bin/cmd.ttp,
- $HOME/bin/cmd.prg and $HOME/bin/cmd.ttp and execute the first file thus
- found.
- Arguments will be passed to started programs in the ordinary fashion
- (basepage via Pexec) and using the xArg protocol. If xArg passing is
- not desired, it can be switched off by typing "set -a".
-
- Any file can be run as a (binary) program with the shell command `exec'.
- So, typing `exec file.xyz' will run file.xyz regardless wether .xyz is
- in $XEXT or not. If .xyz is in $XEXT, file.xyz can be run by simply
- typing `file'.
-
- When using MiNT, background processes may be started with `&', e.g.
-
-
- getty u:/dev/tty &
-
-
- will start the "getty" program in the background.
-
-
-
- SHELL SCRIPTS
-
- A shell script is an ascii file containing shell commands. Lines
- beginning with a # are interpreted as comments.
- Shell scripts can be started just like binary programs. However, the
- extenders of all files to be considered scripts must be stored in the
- shell variable SEXT. The default is ".sh" which should do in most cases.
- Any file can be run as a shell script by using the `.' command. I.e.,
-
- . shscript.txt
-
- will run the file shscript.txt as a shell script. Note: you must supply
- the full filename and extender here, PATH and SEXT are not evaluated.
-
-
-
- SHELL FUNCTIONS
-
- A shell function simply is a shell script held in memory. Any file can
- be loaded to make a shell function by typing:
-
- cmd(filename)
-
- this will load the named file and store it so that it can be called by
- typing `cmd'. If cmd is ommited (i.e. by typing `(filename)'), the base
- name of filename (without extender) will be used. Example:
-
- (showpic.sh)
-
- will load the supplied file `showpic.sh' into memory, making a shell
- function named "showpic".
-
- Shell functions can be created by shell scripts or by typing from the
- keyboard in the following manner:
-
- name()
- {
- .................... any commands
- }
-
-
- Removing:
-
-
- name()
- {
- }
-
-
- or `unset name'.
-
- The shell command `alias' can be used to create brief shell funktions.
- So, `alias ll ls -l' will create a shell function named `ll' which
- executes `ls -l' when called. When using `alias' to rename a built-in
- command, use it prefixed with a `!', e.g.
-
- alias ls ls -C
-
-
- will recurse forever, whereas
-
-
- alias ls !ls -C
-
-
- is correct.
-
- A list of all shell functions can be created with the internal command
- 'fcts'.
-
-
-
- SHELL VARIABLES
-
-
- ...setting:
- VAR=this is the value of VAR
-
-
- ...using:
- echo The value of VAR is $VAR.
- cat $HOME/profile
-
-
- ...protecting against value changes and deletion:
- readonly VAR
-
-
- ...exporting into environment for successive programs:
- export VAR
-
-
- ...listing:
- vars
-
-
- ...removing:
- VAR="" (removes value)
- VAR= (removes variable)
- unset VAR (removes variable)
-
-
- Type `ver -l' to find out the maximum number of shell variables.
-
-
- Predefined shell variables:
-
-
- PS1 The primary shell prompt.
- PS2 The secondary shell prompt, used if additional input is
- required (e.g. when entering shell funktions).
- OKAMISHELL The shell's version number.
- TERM Initially set to "Atari ST" and not yet used any further.
- CWD The current directory, set by the cd command.
- HOME The current directory at the time the shell was started.
- ETC The name of a directory for additional files. Initially
- set to $HOME.
- SHELL Initially set to $HOME/sh.ttp . Should be changed if the
- name of the shell program file is changed.
- PAGELEN The number of lines on the screen to be used by the more
- command. Initially set to 23.
- PIPDIR The name of a writable drive to be used for pipelining
- etc. Initially set to the same as HOME. Should be set
- in profile to be on a ramdisk to speed things up.
- NULL The name of a file or device to which output is to be sent
- which has been redirected to the NULL: device. Initially
- set to PRN: but can be set to a ramdisk file.
- NULL is set to u:/dev/null when MiNT is active so it
- shouldn't be reset then.
- PATHSEP The seperator characters to be used in PATH, XEXT etc.
- Initially set to ",;", i.e. list entries may be seperated
- by commas and semicolons. You may include a colon in
- PATHSEP if you work on the MiNT unified file system (drive U:)
- only, and seperate list entries with colons (in Unix fashion).
- XEXT
- SEXT
- GEXT
- PATH
- explained above.
- CDPATH A list of directories to be searched by the cd command.
- MANPATH A list of directories to be searched by the man command.
- MANEXT A list of file extenders to be recognized as online-help
- text files for external commands, used by the man command.
- HELPFILE The name of the online help file for internal commands.
- Should be set to $HOME/doc/english.doc in profile since
- the default is $HOME/doc/commands.doc (the german instructions
- file).
- CLIPDIR Contains the directory and file of the AES scrap directory.
- Should only be set by the `clipb' command.
-
-