Hi Mateusz, >> Is it ok for you, if I make an official SvarDOS package? > > Sure, it's fine. The reason I didn't do it is because I am unsure how it > should be packaged... I mean, the easy way would be to put it inside > %DOSDIR%\BIN\, but then it would mean that it is not possible to have > FreeCOM and SvarCOM installed at the same time (should it be possible? I
I only see one possible reason: SvarCOM and FreeCOM files are named command.com both. Just name SvarCOM file SVARCOM.COM and set SHELL=C:\SVARDOS\BIN\SVARCOM.COM. > like to experiment with two alternative SHELL= settings, but maybe > that's only me). There is also the problem that SYS looks only in > C:\COMMAND.COM when creating a bootable floppy (I think). It looks for COMMAND.COM on the "source drive". If it doesn't exist, query %COMSPEC% environment variable and copy the file specified instead. From <https://github.com/FDOS/kernel/blob/8c8d21311974e3274b3c03306f3113ee77ff2f45/sys/sys.c#L960>: /* lastly check for command interpreter */ sprintf(srcFile, "%s%s", opts->srcDrive, (opts->fnCmd)?opts->fnCmd:"COMMAND.COM"); if (stat(srcFile, &fstatbuf)) /* if !exists() */ { char *comspec = getenv("COMSPEC"); if (opts->fnCmd || (comspec == NULL) || stat(comspec, &fstatbuf)) { printf("%s: failed to find command interpreter (shell) file %s\n", pgm, srcFile); exit(1); } } } } So, this is no show stopper. The only thing to mention is, that in your current SvarDOS installation, sys.com or format /s, which calls sys.com/sys.exe will never install SvarCOM to the target drive. > Another valid question is how the shell should be upgraded, because > obviously it cannot be "pkg del"-ed first since then the user would be > left with no shell at all... so maybe there must be two copies anyway. Um. What does "pkg update ..." do in the background? Does it do "pkg remove" followed by "pkg install"? Or a "extract all files from the new package overwriting existing files"? I didn't look at the source code, but I guess, it's using the first method, as the second method would leave some old files sometimes. What will happen, if we do a "pkg remove command"? Let's try it... 1. "pkg pull command" -> Placed a copy in my C:\PACKAGES\ folder. 2. "pkg remove command" -> All files but C:\COMMAND.COM (!) were removed and I was returned to the DOS prompt. 3. In my C:\PACKAGES\ folder: "pkg install command.zip" -> All files were installed. 4. Reboot. -> Booted fine. So, it isn't a problem, because: 1) After removing the package, a copy of COMMAND.COM is still present in memory, 2) there's a backup copy C:\COMMAND.COM, although it's only in English, but I think, that's okay for this emergency. On boot if the FreeDOS kernel doesn't find the file specified by "SHELL=...", it asks the user for the path. I just entered "command.com" and found me at the common command prompt. But AUTOEXEC.BAT or FDAUTO.BAT doesn't get executed automatically. Maybe a bug in the kernel or it is by design. But you can just run the BAT manually. After that I did: cd packages pkg install command reboot -> Anything worked as before. To prevent users from deleting their current shell by accident, I thought about some additional code for "pkg remove": If the value of %COMSPEC% is in the list of "pkg listfiles" (converted to uppercase), then present a warning "Are you sure?" with a default to "No". Cheers, Robert -- +++ BTTR Software +++ Home page: https://www.bttr-software.de/ DOS ain't dead: https://www.bttr-software.de/forum/ _______________________________________________ Svardos-users mailing list Svardos-users@lists.osdn.me https://lists.osdn.me/mailman/listinfo/svardos-users