Main page I Packages I Help I Forum
SvarDOS community forum
a place to talk about SvarDOS and other DOS-related things
SvarCOM vs EDR command.com
I understand that SvarCOM is meant to be simple. "It strives to reimplement the baseline functionality of MS-DOS 5/6" as you write.
It's memory footprint, together with the EDR-DOS Kernel, is really impressive:
I have 643.824 Bytes conv. memory free after booting, because CDROM and mouse drivers etc. are in upper memory.
The question for the ordinary user like me is, what are the pros and cons about replacing EDR command.com with SvarCOM.
The only drawback I can find at the moment (for me personally) is a nice (and unique) DR-DOS feature : "IF DIREXIST".
Not really a big deal, but replacing EDR command.com with SvarCOM means I have to change a dozen or more batch files
(which are also used by other DR-DOS flavours, however).
So just a simple question: is an implemention of "IF DIREXIST" either a complicated thing and/or "politically not desired" (in the sense of 'K.I.S.S.')?
Code wise it should be a few lines. And if its helping the users to port their batch files over... For me its a +1 and if Mateusz likes it...
SvarDOS (and by extension, SvarCOM) is meant to reproduce the basic functionality of MS-DOS. "IF DIREXIST" is not recognized by MS-DOS, so batch files using it were never supposed to be compatible with anything besides DR-DOS. And SvarDOS is not DR-DOS (even if it relies nowadays on a kernel offshoot of DR-DOS).
While it is certainly true that supporting such DIREXIST syntax would likely not take much space or effort, it would be however a starting point for slow accumulation of bloat, in a sense. Someone else will ask for some other tiny feature from, say, 4DOS, or some extension from MS-DOS 7, and so on. Where do we set the limit?
It's also worth noting that "DIREXIST" does not seem to provide any practical feature. The universal way to replace "DIREXIST" is to use "IF EXIST DIRNAME\NUL". The result is the same, but compatible with both MS-DOS and DR-DOS systems. Or have I misunderstood the purpose of DIREXIST?
Mateusz
I fully understand that standpoint! However, that is sad in the sense that there are quite a few people who would like to use SvarCOM in a way or another, but will or cannot because of a few missing "things". For example, on the FreeDOS mailing list the topic of providing SvarCOM as an alternative to FreeCOM comes up from time to time. On the other hand, if someone is really interested, there is always the possibility of forking SvarCOM and make e.g. a "SvarCOM-Bloated" of it :)
I fully understand that standpoint, too - I actually expected this answer ;-)
> use "IF EXIST DIRNAME\NUL".
Yes.
In the last years I nevertheless avoided these (simple) replacements in my batch files.
Reason: There was (a long-standing) bug in the FreeDOS-Kernels, I think since 2042.
(Checking NUL directory/drive is broken: "if exist E:\NUL echo E: is present" always identifies E:\NUL as present)
I remember I had to compile the last FreeDOS-Kernel (2043) in 2021 by myself to correct this bug.
Of course FreeDOS-Kernel stuff is not your business, this is the SvarDOS forum :-)
> There was (a long-standing) bug in the FreeDOS-Kernels, I think since 2042.
Yes Frank, there still exists an open bug report for it:
https://github.com/FDOS/kernel/issues/193
Did you fix this for yourself?
Yes, in 2021, for my very 'personal' Kernel 2043, I simply reverted the previous change.
The code responsible for this bug is in newstuff.c, around line 305.
The bug is caused by a change in TrueName(), where code was changed
from
cdsEntry = get_cds(result);
if (cdsEntry == NULL)
return DE_PATHNOTFND;
to
dhp = IsDevice(src);
cdsEntry = get_cds(result);
if (cdsEntry == NULL)
{
/* workaround for a device prefixed with invalid drive (e.g. "@:NUL") */
/* (MS-DOS always return drive P: for invalid drive. Why P:?) */
if (dhp)
{
result = default_drive;
cdsEntry = get_cds(result);
if (cdsEntry == NULL)
return DE_PATHNOTFND;
}
else
return DE_PATHNOTFND;
}
Now truename ("e:\NUL") returns not 'path not found', but 'isDevice'.
> I fully understand that standpoint! However, that is sad in the sense that there are quite a few people who would like to use SvarCOM in a way or another, but will or cannot because of a few missing "things".
Maybe we could start by listing this missing stuff in some bugz item, at least to have an idea of what "the market" wishes for, and then think about devising some rule to select what should and what should not be part of SvarCOM? The current rule is "MS-DOS 5/6 compat", but perhaps we could imagine something smarter. Worth noting btw that I did not follow this rule to the letter myself anyway, since I implemented a very non-standard "ln" command that is SvarCOM-specific (and I like it very much).
> For example, on the FreeDOS mailing list the topic of providing SvarCOM as an alternative to FreeCOM comes up from time to time. On the other hand, if someone is really interested, there is always the possibility of forking SvarCOM and make e.g. a "SvarCOM-Bloated" of it :)
Such SvarCOM-Plus abomination could possibly be integrated in our svn tree, with the ugly/bloaty/non-MS-DOS features controlled by some #ifdef BLOAT_EDITION and a distinct package being generated at build time.
Another option would be to include EDR command.com as a package in the network repo, so DR-DOS users could switch to SvarDOS and then decide if they wish to stick to EDR command.com or use something else.
Mateusz
A humble suggestion:
A solution that has been implemented in an extremely old DOS Shell interpreter was something like COMMAND.COM holding all the "MS-DOS 5/6 compat" that could dynamically load a sidekick MAX.COM if present, which could have all the new/esoteric/BLOAT_EDITION/MS-DOS 7/market stuff.
So from a user perspective it is as simple as having MAX.COM together with COMMAND.COM if you want the bizarre stuff, or just deleting MAX.COM for memory & space saving and to keep it as vanilla as possible.
From a deployment point of view, it shouldn't change that much. Just one additional optional base installation file.
This solution was implemented on X-DOS which started life as a shareware DOS clone in the late 80s, early 90s, and was later bought by a Taiwanese company that still promotes it for embedded/industrial use.
> Another option would be to include EDR command.com as a package in the network repo, so DR-DOS users could switch to SvarDOS and then decide if they wish to stick to EDR command.com or use something else.
Independently from how SvarCOM develops it would be good to have EDR COMMAND in the repo. However, even after cleaning up its source code a bit I am not eager to touch it in case bugs are encountered...
> Such SvarCOM-Plus abomination could possibly be integrated in our svn tree, with the ugly/bloaty/non-MS-DOS features controlled by some #ifdef BLOAT_EDITION and a distinct package being generated at build time.
I also thought of IFDEFs, but not too much. That contributed a large part to EDR COMMANDs source unreadability. For me it became barely readable after throwing out much of it, mainly regarding DR Concurrent. And the indentation, what a nightmare...
> A solution that has been implemented in an extremely old DOS Shell interpreter was something like COMMAND.COM holding all the "MS-DOS 5/6 compat" that could dynamically load a sidekick MAX.COM if present, which could have all the new/esoteric/BLOAT_EDITION/MS-DOS 7/market stuff.
Interesting solution, although it sounds somewhat complex. Another variation would be to have a TSR that intercepts some commands and extends them. There is actually a special interface for this, albeit it is yet to be implemented in SvarCOM:
https://github.com/SvarDOS/bugz/issues/6
This could open the way for anyone to hook into SvarCOM and overlay it with custom/better/bloatier/fancier things.
> I also thought of IFDEFs, but not too much. That contributed a large part to EDR COMMANDs source unreadability.
I admit that I am not very keen about this as well, for the same reason.
Mateusz
It would be helpful if command.com /? and all other svardos commands /? would at least show the version number.
I just wanted to find out the command version number of EDR command in FDT24xx - and got none. I was confused if there is
a new version or not.
A short explanation there with the options would be helpful too. Some commands have, some not. This is confusing. And people do not
know all commands by heart.
In virtualbox I have a strange behaviour at the moment, not sure if it can be reproduced: The english / only works when pressing
the key twice. This happens with BONUX diskette when aborting the installation menu and typing any command /? maybe it has to do with
this Provox software?
Renaming this diskette as BONUS is a little confusing too. Diskette for blind people would be a little bit better.
Hello Fritz! Not sure I understand you correct. Are you speaking of SvarCOM you tested under FreeDOS, or did you indeed test the Enhanced DR-DOS command.com? That one at the moment is not even included in the SvarDOS package repo. SvarDOS command does indeed not show its version when invoking /?. But it is shown when invoking ver at its command line.
SvarCOM's version is displayed under "ver" (or "command /c ver"), but it's a very good point that it should also be shown in the /? screen. I have implemented it in r2370 (to be released as 2025.1 some time later this year).
> A short explanation there with the options would be helpful too. Some commands have, some not.
100% agree. Do you have some examples of commands that are missing help?
> The english / only works when pressing the key twice.
Since you seem to be using the BNS edition, this is normal. The "/" key is the default shortcut for accessing PROVOX functions.
> Renaming this diskette as BONUS is a little confusing too.
BNS does not stand for "BONUS" but for "Braille 'n Speak". It is the name of the voice synthesizer that this bootable CD is compatible with. Perhaps it is not described well enough on the website. Any suggestion about how to make it clearer?
Mateusz
Hi,
I ran some more intensive tests with a svardos (no BNS) installed from diskette to HD:
1.) c:
a: (without a diskette inside):
LESENFEHLER (correct in german: LESEFEHLER, please tell it Bernd)
(A)bort, (r)epeat, (s)kip --> abort+repeat repeats endless, only skip works.
Would be fine if you add the undocumented /f option that fd command contains.
But it should already work in EDR?
See:
https://sourceforge.net/p/freedos/bugs/23/
2.) Tree shows help but no version number.
3.) amb shows short help but no version number.
I tested a lot of external programs of Mateusz and found only these two without version number.
4.) command.com commands:
a typical message:
prompt /? Ändert die DOS-Eingabeaufforderung (Changes the DOS command prompt)
PROMPT [neue Eingabeaufforderungsspezifikation] PROMPT (new command prompt specification]
--> not very helpful for users. There are more, if you need them, I will run the commands again and check for such missing informations
While testing command, I noticed that commands that are part of FD command are not implemented. This is only for information,
as it maybe that you do not need it:
a) alias --> command not found (really not needed - or not shown by alias /?)
b) beep --> command not found (was a little astonished)
c) cdd --> command not found
d) ctty --> command is not implemented
e) dirs --> command not found
f) lfnfor--> command not found
g) loadfix --> command not found
h) memory --> command not found
i) popd --> command not found
j) pushd --> command not found
k) which --> command not found
l) "?" --> command not found, this would be very helpful, as it lists the existing commands in command.com. But of course it needs space.
BNS / Braille 'n Speak:
What about "Braille" or "Blind" or something like this. BNS confuses FD users.
> LESENFEHLER (correct in german: LESEFEHLER, please tell it Bernd)
Already corrected :)
> LESENFEHLER (correct in german: LESEFEHLER, please tell it Bernd)
Fixed already (thanks, Bernd!) :-)
> Would be fine if you add the undocumented /f option that fd command contains.
This apparently comes from MS-DOS 6.x. Sounds possibly useful. I made a bugz issue about this for future implementation:
https://github.com/SvarDOS/bugz/issues/160
> 2.) Tree shows help but no version number.
Version is displayed now in SvarDOS TREE ver 20250111.
> 3.) amb shows short help but no version number.
Next AMB version will display its version in help screen.
https://sourceforge.net/p/ambook/svn/231/
> 4.) command.com commands:
> a typical message:
> prompt /? Ändert die DOS-Eingabeaufforderung (Changes the DOS command prompt)
> PROMPT [neue Eingabeaufforderungsspezifikation] PROMPT (new command prompt specification]
> --> not very helpful for users. There are more, if you need them, I will run the commands again and check for such missing informations
Would you be willing to contribute some improvements to the SvarCOM's help messages? It would be very nice to have better helps. But as you know we need to be cautious about memory usage, so the help messages would need to be informative but at the same time as short as reasonably possible.
> While testing command, I noticed that commands that are part of FD command are not implemented.
SvarCOM's goal is to loosely mimick MS-DOS.
> BNS / Braille 'n Speak: What about "Braille" or "Blind" or something like this. BNS confuses FD users.
I will look into this, thanks.
Mateusz
4.) Let me see what I can do for you. It will last a while as I still work on german FD help.
Questions:
Where can I download the actual german and english text?
Does it have to be written in UTF-8 or (I assume so) in CPxxx?
Is there a maximum length for the text? I know as short as possible, but this is sometimes a problem.
Does svarcom use the same options as FD or does it use others?
> Where can I download the actual german and english text?
The original "source of truth" is the svardos svn repository, but if you are not comfortable with svn then you can also fetch the SvarCOM strings from our github mirror via a clickable web interface:
https://github.com/SvarDOS/core/tree/master/svarcom/trunk/lang
> Does it have to be written in UTF-8 or (I assume so) in CPxxx?
UTF-8 preferred, but of course if for some reason you submit files in an 8-bit codepage I will convert them, no issue.
> Is there a maximum length for the text? I know as short as possible, but this is sometimes a problem.
There is no hard limit. The ultimate goal is to keep SvarCOM overall as compact as possible, so help screens should follow this spirit as much as possible and reasonable.
> Does svarcom use the same options as FD or does it use others?
SvarCOM tries to mimic MS-DOS 5 (sometimes 6), hence options may differ from what FreeCOM supports. The current help screens in SvarCOM should provide at minimum the supported options with some (possibly very short and enigmatic) description.
Mateusz
Ok, i ran a quick test. There is not so much to add than I thought.
Main thing is prompt $Q,$$, $T, $D, $P, $V, $N, $G, $L, $B, $H, $E, $_ + a short comment
I will have to run a test with "echo." and "set". I think this is doable when I have a little time.
svarcom english would need the following, but I do not know the numbers:
Could you add these positions at english svarcom text file and I could add it in english and ask Berki to add it in tr and fr?
Thx
Fritz
# changes at ECHO: added 31.X and 31.Y (as "31.XY" numbers are unknown)
# changes at PROMPT: added 33.A till 33.O (as "33.AO" numbers are unknown)
# changes at SET: added 23.A till 23.D (not sure which options work)
# ECHO
31.0:Displays messages, or turns command-echoing on or off.
31.1:ECHO [message]
31.X:ECHO.
31.Y:ECHO. Shows an empty line (batch files only).
31.2:Type ECHO without parameters to display the current echo setting.
31.3:ECHO is on
31.4:ECHO is off
# PROMPT
33.0:Changes the DOS command prompt.
33.1:PROMPT [new command prompt specification]
33.A:Prompt can be made up of normal characters and the following special
33.B:codes:
33.C:$$ $ (dollar sign)
33.D:$_ Carriage return and linefeed
33.E:$B | (pipe)
33.F:$D Current date
33.G:$E Escape code (ASCII code 27, see NANSI.SYS).
33.H:$G > (greater-than sign)
33.I:$H Backspace (erases previous character)
33.J:$L < (less-than sign)
33.K:$N Current drive
33.L:$P Current drive and path
33.M:$Q = (equal sign)
33.N:$T Current time
33.O:$V The SvarDOS command shell version number.
# SET
23.0:Displays, sets, or removes DOS environment variables.
23.1:SET [variable=[string]]
23.2:variable Specifies the environment-variable name
23.3:string Specifies a series of characters to assign to the variable
23.A:/C
23.B:/? Other Options not known.
23.C:/? "
23.D:/? "
23.4:Type SET without parameters to display the current environment variables.
23.5:Not enough available space within the environment block
Hi, I have added the requested strings in this commit:
https://github.com/SvarDOS/core/commit/0b62badca6e1e1011a1e6f698307e74f65214c2b
I did not, however, add anything to SET, because SET accepts no options at all.
I hope it helps. :-)