B.EXE Changes / Bug Fixes Version 1.1 all done around November 26, 1994. Fixed a bug that incorrectly reported a directory with even megabytes of files as multiples of .1 Meg of files. This had to do with the fact that, in computing the number of Megs of files, I do not actually do any floating point dividing, but instead do integer math, and the error came from trying to round the numbers. I dropped the number rounding. I changed the program so that it will read its "name" from the command line, so that if you change its name, such as from B.EXE to PROGRAM.EXE, it will "know" itself as PROGRAM.EXE. The help text ( /? for the switch ) will reflect this, as will the system variable that must be set. Thus, if you don't like the name B.EXE, you can change it for all practical purposes. However, the .EXE ending needs to be kept. I fixed the counting for when and where to pause when the number of files and directories would be off the screen so as to take the bar along the top that OS/2 creates in command line sessions by default into consideration. I added a way to stop the directory scroll at a certain point, so as to get back to the command line. All one has to do is hit the 'Esc' key now, and you immediately get the command prompt, and all of the entries that were on the screen stay on the screen. If one used the system variable, there was no way to clear switches that were already set, from the command line. Now all the switches, except for the ones which control how many columns appear on the screen ( /w /n /d /l ) and the one that changes the highlighting extensions (/c ), will now toggle, so that if you use them twice, they are negated. The reason I don't do this for the ones that control the columns is that the /n switch effectively clears both /w and /d already. I don't know if anyone will actually use this toggle 'feature', but it's there. Version 1.11 all done around December 5, 1994. When rewriting internal stuff for 1.1 fix, I screwed up the /D switch so that it does not show the size of files. I fixed this so that you can see the sizes now. This was corrupted in both versions, DOS and OS/2. Version 1.2 all done around March 18, 1995 I am not including IBM Works versions of the text since I don't have it installed since I have Word Perfect 6.1 now to use. I brilliantly realized that having two separate source files for the two versions was a little stupid, since I can use the #ifdef directives in C to add in specific code. Now I don't have to worry that I forgot to change in one version something I changed in the other. This was a big problem before. I cut out a lot of dumb code, by thinking up clean and compact C++ code. I am now utilizing unions to the maximum. Fixed a lot of bugs. Fixed /S not working in OS/2. Fixed a problem with /C being the last parameter in the environment variable. If /C was the last thing in your environment variable, the next thing on the command line would be looked at as if it was an extension for /C; this was fixed. I fixed a few other /C problems. Due to user demand, I have added /A to allow one to change the default colors of my program. Why did I put it as a switch? Accessing a file is WAY too slow, and file access adds a lot of code. Another environment variable would be too weird. A switch is fast, and it allows one to use it in aliases. Obviously, I wouldn't expect anyone to type in /A with all 9 colors every time. Due to user demand, I added in sorting (with reverse sort also). You can sort by name (default), extension, time, and size. You can choose to not sort. The directories stay grouped together out of the way; files and directories are separate classes in my program, and I didn't feel like messing with ungrouping them. I changed the /O switch from showing only files, to the sort switch, to be like DOS (sort of), and the old /O became /K instead. (From "files O'nly" to " K'ill subdirectories", I guess.) Due to user demand, I added more extensions to the /C switch. I added one more color (dark green by default) for the sixth extension, then extensions 7 - 12 take on the same colors as extensions 1 - 6. Hopefully twelve extensions are enough. I allowed /L for the DOS version to work. /L will now show explicitly what attributes the file has, especially since files consisting only of numbers can not be capitalized for read-only files. I also added, for laughs, the time up to a half-second on the files and directories; why anyone would need this is beyond me. Due to user demand, using .ZIP for instance as an argument would be transformed to *.ZIP, as in MSDOS. Also, the DOS version would transform ABC* as ABC*.* (the OS/2 version doesn't need it). Future Changes: I really need to add in the OS/2 B.EXE the size of the enhanced attributes somehow, as they would show up under the /L switch. This will probably require delving into the OS/2 specific API, since I've only effectively ported an existing DOS program of mine with slight modifications, using Borland C++. I plan to make the OS/2 version use true OS/2 API calls in the very near future. I might add the ability to ungroup the directories and subdirectories from each other, but that might be a little hard, due to the way I wrote B. I plan to add the ability to read ZIP files files if they are given as an argument, and list the files as if they were in an actual directory. This will take some time since I know nothing about how ZIP files are set up, still. With this option, I won't need to use UNZIP -v to read ZIP file directories. If you find any bugs in my program, or want to suggest a change, E-mail me at: dohnarms@uiuc.edu or mail me at: Dohn Arms Loomis Laboratory of Physics 1110 West Green Street Urbana, IL 61801-3080 I am rather open to suggestions to improve my program if it doesn't take a lot of effort to hack it into my code or if it doesn't get in the way of this being mainly an alternative for the DIR command. ("B now will answer your EMAIL for you, write your physics doctoral thesis, generate the Great American Novel, and prove Fermat's Last Theorem, while still giving you the contents of a directory, which is what you've come to expect from B!!!")