Dec 252017
 
CTSHELL is a directory manager and a program launcher.
File CTSHL114.ZIP from The Programmer’s Corner in
Category File Managers
CTSHELL is a directory manager and a program launcher.
File Name File Size Zip Size Zip Type
CTSHELL.CFG 7120 2465 deflated
CTSHELL.DOC 30300 8161 deflated
CTSHELL.EXE 52524 31596 deflated

Download File CTSHL114.ZIP Here

Contents of the CTSHELL.DOC file





C T S H E L L . D O C v1.14 Oct 19, 1990




PURPOSE CTSHELL is a directory manager and a program
launcher. It was designed to be used in
programming classes that its author teaches, to
make it simple for students to get to the right
place to work on a lab assignment. Its utility is
not limited to the classroom, however. It can be
used for day-to-day computing, including program
development, communication, and more.

IT DOESN'T... Something that CTSHELL *doesn't do*
is even more important than what it doesCTSHELL
doesn't get in your way! When you're using
CTSHELL, you can type DOS commands just as if you
were out at the ordinary DOS prompt. You can take
advantage of everything CTSHELL has to offer
without giving up much of anything in exchange.

XMS/EMS/DISK SWAPPING. In fact, CTSHELL uses a
sophisticated swapping method that lets it take
full advantage of your EMS or XMS memory, and it
swaps to disk on computers that have neither.
That means all but a few K of your available RAM
is free to run big programs from CTSHELL.



OFF TO A You can get a quick idea what CTSHELL is all about
QUICK START by starting it up in a directory that has a
configuration file for it (more about the .CFG
file later...). If you've unZipped the original
archive in a temporary directory, go ahead and
start the program with the command,

C:\> CTSHELL

MOVING AROUND. You can move around the listing of
files with the up and down arrow keys, and the
left and right arrow keys will provide access to
the menus at the top of the screen.

FILE TAGGING. Tagging is provided by the first
four function keys, as the little reminder window
shows you, and there are almost as many operations
that can be performed on tagged files as there are
for individual ones.

DIRECT DOS COMMANDS. Notice that you can enter a
command normally. You can even change drives or do
a CD command to a different directory, and CTSHELL
will realize what you did. It will automatically
update its screen for the new directory.
If you perform any operation that changes
information on the current screen, CTSHELL will
sense that automatically and update the screen.
Later sections of this document provide greater
insight into CTSHELL's capabilities. You'll surely
want to modify the CTSHELL.CFG file to customize
it according to your own needs and tastes.


MODIFYING
CTSHELL.CFG Note: This overview is kept brief, because
nearly all you need to know about modifying
CTSHELL.CFG is explained in the file itself.
It is suggested that you print or display a
copy of that file while you look this over.


CTSHELL is a very configurable program, and relies
heavily on the entries that you make in
CTSHELL.CFG. The copy that you started with has
some suggested entries (including a set of colors
that I personally like). Use the comments in the
file to guide you in setting it up as you like.

BRACKETS AND BRACES. Note that all the entries
that are meaningful to CTSHELL are enclosed inside
braces or brackets. Thus, everything outside those
symbols is considered to be comments. Words
inside brackets, such as [colors] tell CTSHELL
where the major sections of the config file are,
and entries inside braces, such as {program.exe}
provide the values and settings that it needs.

MULTIPLE CONFIGS. CTSHELL is designed to read a
configuration file name from the command line when
it is started, and to use the configuration path
pointed at by the CTSHELL environment variable if
no configuration file name is given at startup.
If it *still* doesn't have a file name to use, it
will default to CTSHELL.CFG in the current
directory.
That means that CTSHELL may always be started
so that it uses your choice of config files. You
may want to create one specially for use in
program development, another one especially for
communications, another for word processing, etc.
You might want to set up different config
files for different people who use a computer.
Each user could have his or her own paths and
programs easily available.
However, most users will probably find it
convenient to use a single copy of CTSHELL.CFG
that is described by the CTSHELL environment
variable. You can set this environment variable
in your AUTOEXEC.BAT file with a statement like
this:

SET CTSHELL=C:\pathname\filename.ext

For example, if the configuration file were kept
in the C:\BIN directory, and named CTSHELL.CFG,
that SET command might look like this:

SET CTSHELL=C:\BIN\CTSHELL.CFG

The program could then be started from anywhere
and it would load its configuration properly from
the specified file.

COLOR OPTIONS. The first nine entries in the
configuration file are for color choices. CTSHELL
uses your specifications for the colors displayed
on the screen. All colors are given in
hexadecimal numbers, with the first (higher) digit
specifying the background, and the second (lower)
digit specifying the foreground.
On all color monitors more recent than CGA,
CTSHELL can use all 16 colors in both the
background and the foreground. With CGA monitors,
you can use the 8 ordinary colors in both the
background and foreground, and the bright colors
only in the foreground.

Digit Color Digit Color

0 Black 8 Bright Black
1 Blue 9 Bright Blue
2 Green A Bright Green
3 Cyan B Bright Cyan
4 Red C Bright Red
5 Magenta D Bright Magenta
6 Yellow E Bright Yellow
7 White F Bright White


POINT-'n'-SHOOT PROGRAMS. The next series of
entries tell CTSHELL what programs you use for
day-to-day activities. There are several that are
so commonly used that we can assign values to them
and put them into a menu for easy access.
Everyone uses an editor, for example. Most
all programmers use at least one compiler and a
MAKE utility. This Point-'n'-Shoot section
establishes what those programs will be. One
thing they all have in common is that they all use
the current (or tagged) file(s) as a command-line
argument automatically.
As the comments in the CTSHELL.CFG file show,
you can provide a directory to change to and/or a
program to run. Either may be empty. Note that
CTSHELL calls your default command processor, the
one that your COMSPEC environment variable
defines. Thus, if you are using a command
processor like 4DOS that provides aliases, you may
feel free to use those aliases as commands in your
CTSHELL.CFG file.
If you need to provide a runtime parameter
for your program, you may use a switch option
like:
{ASK:ZIP File Name?}

That will cause CTSHELL to pause before executing
the program to prompt you for a "ZIP File Name".

DIRECTORIES/TASKS. Following the color settings
and program assignments, you can provide up to 20
entries that specify tasks you want to be able to
pick out of a menu. Each set of entries describes
what you would like to show up in the menu, where
to go before starting the task, and what program
to run once you get there, as well as some flags
and options.
If you want to change to a directory but not
execute a program once you get there, just leave
the brackets for the program name empty. If you
want to execute a program without first changing
to another location, leave the brackets for the
path name empty. That will satisfy CTSHELL's need
to see an entry, but also will let it know not to
take any action.
If you need prompted for an optional switch,
you may use {ASK: ... } in this section as well.



TAKING A Once you have CTSHELL.CFG modified appropriately,
SECOND LOOK you're ready to try out everything it has to
offer. Notice that you can move up and down
through the listed file names with the up and down
arrow keys. Touch-typists may appreciate that
duplicates the up arrow, and
duplicates the down arrow.

DOS OPERATIONS. CTSHELL improves on many common
DOS operations. Its File Move function moves
directory information without copying and deleting
the file contents, so long as the source and
destination are on the same drive. If they are on
different drives, it copies, then deletes the
source.
CTSHELL's File Copy function dynamically
allocates a copy buffer the same size as the file
being copied, provided there's room in the data
segment. Thus, CTSHELL copies large files in
approximately 40K chunks, instead of DOS's default
4K size.
CTSHELL displays files in lowercase letters,
as is the default for 4DOS, instead of the
uppercase that DOS uses in its DIR listings.
Directory names are displayed in uppercase.
CTSHELL contains its own DOS critical error
handler, so its display is not disrupted by
the occasional "Abort, Retry, Ignore" that
may happen when you try to access an empty
floppy drive. You're given a chance to fix
the problem and continue, or exit back to DOS
to handle it there.

PRESSING . If you press while on a
file, one of a number of things might happen:

(1) if it is a .COM, .EXE, or .BAT file it
will be executed,

(2) if it is a file for which one of your
Point-'n'-Shoot programs has reserved
the extension, that program (such as an
editor) will be started up using it as
an argument,

(3) otherwise, if it is a directory, CTSHELL
will change to that directory for you.
Note that the special name .. represents
the parent of the current directory.

THE DELETE KEY. Because it often happens that we
need to delete a single file, CTSHELL uses the
key to delete the current file (the one that
the cursor bar is currently highlighting). So
that a file is not deleted accidentally, CTSHELL
will beep and ask you to press the key a second
time. Pressing any key other than for the
confirmation aborts the deletion.

TAGGING FILES. If you begin tagging files, you'll
see that the number of bytes that are tagged is
displayed on a special little pop-up. As more
files are tagged or untagged, this is adjusted.
When no files are tagged, the pop-up disappears.
The first five function keys can be used to
toggle the tag condition for a single file, tag
all the files, untag all the files, invert the
tags, and tag files by name. You can tag all the
source files, copy them to a floppy disk, then
invert the tags and copy all the others somewhere
else.

USING THE MOUSE. The mouse can be used to access
the menus in the customary way, and it has various
effects elsewhere on the screen. For example, the
scroll bar on the right can be used with the mouse
to scroll through the list of files in the manner
that has become conventional.
There is a list of the function keys that are
implemented in CTSHELL. Clicking on an item from
that list has the same effect as pressing the
respective function key.
Clicking the left button once on a file entry
makes that the current file. If you double-click
on a file entry, it means the same thing as
pressing for that file (see above). If
you click the right button on a file entry, it
will tag or untag that file.

THE ALT KEY. You might expect that the key,
when used with a letter that begins a menu name,
might open that menu as well. It does. If you've
opened an menu and decide not to do anything with
it, press to close it.

EXITING. When a menu is not open, pressing
will exit from CTSHELL. So will , and
there's a menu entry that will work as well. I
just HATE it when I can't figure a way out of a
program.



CTSHELL MENUS CURRENT FILE. This menu contains the
Point-'n'-Shoot entries for the current file.
Selecting one applies that operation to the file
that is currently highlighted.
This menu always offers the built-in features
of CTSHELL, such as changing file attributes,
copying, deleting, moving, renaming, etc. In
addition, it will contain entries for all the
Point-'n'-Shoot options you establish in your
CTSHELL.CFG file.

TAGGED FILES. The provided features are the same
as for the current file, except for renaming. In
addition, this menu will list all the
Point-'n'-Shoot options that you've specified will
work with multiple files.

DIRECTORIES/TASKS. From the section of the same
name in your CTSHELL.CFG file, this is the menu
that lets you move easily to the place where you
want to work on a project, and start the program
that you need when you get there.
In the classroom, this is useful for listing
the various lab projects. At home, it's useful
for transferring email, running an offline reader,
starting a compiler environment, and much more.

PROGRAM. This provides a DOS SHELL for those
times when you really prefer to use the regular
command line. That will allow you to use the
command repeat feature of your command processor,
if it has such a feature.
In addition, there are two options that will
take you directly to your LIB directory and to
your INCLUDE directory. For these to work well,
the environment variables that define these two
must contain a single path each.
There's an option to exit from CTSHELL in
this menu. Note that of no menu is open you can
also exit with or with .

UTILITY. CTSHELL offers a CHKDSK option (it uses
the ordinary CHKDSK.COM from DOS) and it will
format floppy disks a bit more conveniently than
the regular DOS format.
If you have DOS 3.0 or better, you can select
a no-frills format (no prompt for volume name, no
prompt for format again), or you can select a
complete format option. To format a single disk
quickly, the first option is preferred. To format
a stack of disks, you'll want to select the second.
To make it safer for classroom use, CTSHELL
does not offer a direct menu selection for
formatting hard drives. However, there's nothing
to prevent you from typing in a FORMAT C: command
if you really want to.



TO BE VERY I realize that there are some additional functions
HONEST that might make CTSHELL more useful. My first
design consideration was to produce the most
utility from the smallest size program. CTSHELL is
less than 50K, and swaps in such a way as to be
the equivalent of about 5K.
My second consideration was to make this a
quick job. I wanted something to take the place
of the DOS 4.0 SHELL, not something to take the
place of DesqView or Windows. CTSHELL was written
in a few days using Microsoft C6.0. (A version
was also compiled using Turbo C++, but that was
always about 15% to 20% larger from the same
source code.)
When time permits, CTSHELL v2.0 will add
command-line editing (a la CED and DOSEDIT).
Synonyms (aliases) are not planned, as CTSHELL
calls the default command processor. Those using
CED, DOSEDIT or 4DOS should find that their
aliases are not affected adversely by CTSHELL.
Suggestions from those of you who use CTSHELL
for additional features you'd like to see would be
appreciated.



OWNERSHIP AND CTSHELL and its accompanying documents are
COPYRIGHT Copyright (C) 1990 Jerry Houston and Computer
Training, All Rights Reserved.
Those who agree to the terms and conditions
stated below are welcome to use it for any
personal purpose.

Note that Windows is a trademark of Microsoft
Corporation, and Desqview is a trademark of
Quarterdeck.



TERMS AND Neither the author nor Computer Training warrants
CONDITIONS that CTSHELL will do anything, or that it won't do
anything. Users assume full responsibility for
their use of, misuse of, abuse of, or inability to
use, the program.
You are free to use CTSHELL personally, and
to pass it along to others, provided that you
distribute an intact set of files containing:

CTSHELL.EXE - executable program file
CTSHELL.CFG - example configuration file
CTSHELL.DOC - this document

Anyone who is interested in using CTSHELL for any
commercial purpose must first obtain written
permission from the author.



SPECIAL NOTE ...is due to Marty Del Vecchio for his excellent
OF THANKS swap() function. Without it, CTSHELL would not
have been available in this XMS/EMS swapping
version this soon.
Other C programmers who would like to add
this capability to your programs can find it in
the public domain and downloadable from many BBS
systems. The version used here was 3.0, and it
was packaged as SWAP300.ZIP.



VERSIONS v1.00 Original concept, distribution stopped
almost at once to implement additional
features and do further testing.

v1.10 First real release, 10/14/90.

v1.11 minor bug-fix, 10/15/90.
Linked directory list was not properly
freed, making it possible to run out of
room for it during a long session.
Added display of remaining space in the
list.

v1.12 features added, 10/16/90.
File copy was not preserving time and date.
Now displays current disk free space.
If mouse is clicked on function key label,
that function is invoked.
Speeded up mouse processing.
Extended mouse double-click interval from
6 clock ticks to 8.
Modified file copy to allow specifying a
destination file OR directory instead of
just a destination directory--now works
just like DOS copy in that respect.
Improved handling of extensions for
invoking Point-'n'-Shoot programs. Now
doesn't confuse .COM with .C and try to
edit it.
Now uses Marty Del Vecchio's v3.0 of swap()
(previous versions used v2.01).

v1.13 features added, 10/18/90.
Modified menu process routine for more
intuitive movement of cursor bar.
Added to tag files by name. Uses
standard DOS wildcard characters ? and *.
Added to return to original home
directory if an application program
changes the current path.
Added to load a configuration file.
Defaults to CTSHELL environment variable
path if a new path is not supplied. Makes
it easier to modify the config file and
reload it quickly.

v1.14 minor bug-fix, 10/19/09.
Fixed a minor bug that selected files with
no extensions when *.ext was specified as
a wildcard name. Now selects files with no
extension only when *. is used.
Wasn't updating screen after changing the
attributes of a bunch of tagged files. Was
updating next time the screen was refreshed.


THE AUTHOR JERRY HOUSTON

Computer Training
7016 NE 137th ST
Kirkland, WA 98034

Jerry may be contacted on his Wildcat BBS system,
called Programmer's Resource. Phone numbers are
(206) 823-2831 and 823-1917. ProgRes BBS relays
selected conferences from the Intelec, SmartNet,
and WestNet BBS networks.


 December 25, 2017  Add comments

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)