New tools released: COUNT and MIRR*.BAT, UNDELETE updated, varia.
Eric Auer <[email protected]> Thu, 7 Nov 2002 18:25:30 +0100 (MET)
| Newsgroups | gmane.os.freedos.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi, I have been quite busy with UNDELETE and related stuff the last
24 hours... So here are the news:
c:\>undelete dirsave q:\foo\bar d:\foodir.bin > d:\foodir.txt
is now allowed, the q: gets ignored and c:\foo\bar gets saved.
If you need to actually save q:\foo\bar, do:
pushd
cdd q:\foo\bar\
undelete q:\foo\bar ...
popd
However, I had kind of the opposite problem (%_CWD% of the new freecom
contains the current drive as well, but undelete does not want a drive
selection on the command line - it uses the CURRENT drive instead), so
I like the way things are done now. Of course,
undelete \foo\bar ...
... uhm, sorry, whereever I wrote "undelete q:..." I meant actually
"undelete dirsave q:..." ...
Whatever. I wanted to say "undelete dirsave \foo\bar ..." still is the
official and recommended syntax.
Another addition is that UNDELETE now handles Long File Names better:
...
SEHRSE~1.NAM 04:59:20 21.10.2002 @00046, size 0000000005 a
...
LFNpseudo: ?s?e?h?r.?s? 00:03:10 08.03.1980 @00000, size 0003014770 <LONG>
Partial name: <sehrsehrsehr.> Part=01 (---,---) Shortname checksum=0xE0
LFNpseudo: ?l?a?n?g.?e? 00:03:40 05.03.1980 @00000, size 0003014761 <LONG>
Partial name: <langer.datei.> Part=02 (---,---) Shortname checksum=0xE0
LFNpseudo: Cn?a?m?e.??? 31:63:62 31.15.2107 @00000, size -0000000001 <LONG>
Partial name: <name? > Part=03 (EOF,---) Shortname checksum=0xE0
...
As you can see, because the "LONG" attribute may be set in error, the
"if this was a short file name normal directory entry" values are still
displayed, but a bonus line for decoded LFN data has been added.
UNDELETE has also been changed so that it no longer needs a NASM assembly
part to access big harddisk partitions (> 32 MB). Please tell me if there
are bugs here. Do not worry, sector-wise access is read-only in undelete.
I have added the batch files MIRROR and MIRRTREE, which make use of GLOBAL,
COUNT (see below) and FreeCOM 0.83 beta 50 features to backup some data:
MIRROR saves root directory dump (no listing), boot sector and both FAT
copies to files in a target directory at your choice (may not be on the
current drive, as undelete always insists on source (current) and target
being different).
MIRRTREE saves directory dumps and listings starting from the current
directory and including all subdirectories to files in a target directory
at your choice (same limitations as above).
Both MIRROR and MIRRTREE are able to COUNT up file names until they find
a free name: That way, they will not overwrite old files. For log-rotation,
remove some of the old files and MIRROR and MIRRTREE will re-use the names
that you have freed. Both tools check if the tools that they need are
installed before starting to do their job. Please do not fool them by
installing the needed tools in the current directory, the tools must be
findable in a PATH directory.
GLOBAL is a tool that just runs the command that you give it as an
argument several times: It changes into all subdirectories and runs
the command in each of them. Not by me. No author known. Public domain?
COUNT is a tool that grabs a COUNT environment variable from the environment
of its *parent* process and increments it. Very foolproof. But it definitely
sucked that I had to rewrite getenv and putenv to allow manipulation of the
*parent* environment (otherwise, only count itself and its non-existing child
processes would notice the changed variable!)...
Example use:
set COUNT=0000
:loop
if not exist file%COUNT%.txt copy template.txt file%COUNT%.txt
count
if not x%COUNT%==x0042 goto loop
Bonus info to Bernd Blaauw:
Well, happy birthday!
Concerning Linux, you may, but do not have to read lots of docs. The other
option is just "click button to install" and then "click to open file" and
so on. Debian and Slackware users will hate me for that statement :-). But
SuSE and Mandrake and maybe RedHat and others actually are that easy to use.
About Mozilla, I remember that Outlook Web Access (horrible thing! ; to
separate addresses, no "select all" button and you need to navigate on sub-
menus far too often, e.g. for attachments. Not to mention the problem that
it ALWAYS seems to send text+html multipart mail in UTF-8 encoding, most of
the time even base64/uuencoded. Yuck Yuck Yuck) would work if you simply
enable all the crap from Javascript to Cookies. It even works with Netscape
that way.
I would also like to share your display bug issues with an off-topic bug:
"echo." does not display an empty line. It just displays nothing. Sigh.
As usual, you can get the software at:
http://www.coli.uni-sb.de/~eric/stuff/soft/ - do not forget to download
the new FreeCOM 0.83 beta 50 as well, as announced on http://www.freedos.org/
:-). My batchfiles use the %_CWD% (contains the value which "cd" prints when
given no arguments - kind of the current working directory) and the
%ERRORLEVEL% functions, and beta 50 fixes an important bug in XMS_SWAP plus
a bug in "/?" handling in "if", among others.
Current highlights of specials/ and by-others/:
The MetaKern boot menu (should I add options to boot from A: and/or B: to
the menu?), the VolInfXL "statistics over all harddisks" tool (kind of like
LWInfo), the DOS port of DOSFSCK 2.8 (sorry, still did not find the time to
add a disk driver: Only disk images supported by the DOS DPMI version yet),
and a text about freedos-config (yawn).
Most recent additions to by-others are DRL203 (as noted, still contains a
few bugs: My bugfixed DRL101 may be better under some circumstances - or
use DRL204 when it comes out. Quite nifty sorting directory lister, dir /o)
-and- my translation of the comments of the old 1995 original UMBPCI version
source code.
Recent additions to the normal download directory are EECHO (escape-echo,
there is also a .sys version in lbacache), SYSMEM (shows technical memory
status in config.sys), LOCKTONE (tiny "beep when shifts change" driver),
KBDEA (very tiny German keyboard driver, layout modified slightly), COUNT
(also part of UNDELETE, see above) and a new wrapper batch file for TERMINAL.
LBAcache has improved statistics since August, but you still have to wait
some days for the "less DOS RAM and much more XMS" update, which may also
bring support for 8 harddisk and mixed LBA/nonlba BIOSes, but will neither
bring write delaying nor dynamic geometry yet - sorry, trying to cache floppies
of other sizes than 1.44MB will still mess up data copied to/from them.
Call for participation: I am currently looking for people who could
- combine the recent memory FAQ mails into a technote
- add protected mode disk access functions (int 25/26) to DOSFSCK.EXE
(see my extensive doc collection mails on fd-dev :-))
- write UNERASE: this would run undelete dirsave, grep all lines with
"UnDelAble:" in them, parse their filename, cluster number and size,
calculate the size in clusters (can use the geometry info on top of
the undelete output), prompt the user for a new 1st character of the
filename, and use all this info to actually UNERASE files in the
directory given by the user that match the filespec given by the user.
UNERASE will call UNDELETE to perform this task (copy the data of the
deleted files to a directory on another drive selected by the user),
but will be easier to use (and less powerful/flexible) than UNDELETE.
- give me benchmarking/opinion feedback on LBAcache (with respect to
element size, XMS size, dynamic geometry detection, ... please do not
compare LBAcache with other caches that have delayed writing turned
on, I know they are faster. I mean, use /X for smartdrv and ... for
nwcache for useful comparisons).
- re-pack and "GNUify" (add disclaimers without changing filedate to
source files) the TERMINAL, using bin\ doc\terminal\ source\terminal\
and so on, including terminal-rom.
- give feedback on other projects, like metakern (again: A:/B: boot option
to be part of the menu?)
- document the KERNEL config.sys menu "for dummies". Quite easy, but should
be done anyway. I can send you an example of a menuized config.sys...
Closing words:
Anybody interested in yet another tiny (1/4k or so) tty speedup tool
(speeds up int 10.2 / 10.9, the ones used by DOS, but is quite unflexible)
and "make text executable" tool (useful to compress text and still be able
to read it - 1/4-3/4k overhead, all vertical scrolling keys supported, no
other features) ? If yes, do you feel like translating them from MASM to
NASM syntax ? Otherwise, I would do it. Some day...
Happy FreeDOSing! Cheers, Eric.