Yes. The shell is pointed to by the variable COMSPEC
. For example in MS-DOS the default shell is COMMAND.COM
which is stored on the root folder of the system drive
COMSPEC
or ComSpec
is one of the environment variables used in DOS, OS/2 and Windows, which normally points to the command line interpreter, which is by default COMMAND.COM in DOS or CMD.EXE in OS/2 and Windows NT
You can see the variable in Windows even though DOS is not available because it may be used to run shell commands from an executable or a script
C:\Users\user>set comspec
ComSpec=C:\Windows\system32\cmd.exe
As mentioned above, COMMAND.COM
is the default shell but you can always change it and/or add additional parameters in CONFIG.SYS
using SHELL
or SHELLHIGH
SHELL=C:\DOS\COMMAND.COM C:\DOS /E:512 /P
For example FreeDOS doesn't store the shell at the root level but its own directory
Many alternative shells for DOS like have been produced to add many useful features like auto completion, ANSI commands... The most famous one being 4DOS
4DOS is a replacement for command.com, the command processor included in most versions of DOS, far more powerful and flexible, however, than this feeble program. After many years of being commercially successful, 4DOS is now made available for free by its author, Rex Conn of JP Software, at their Downloads Page. It's officially unsupported, though the support forum will generally try to answer your questions.
https://www.4dos.info/4dinfo.htm