**************************************************************************** DoubleTake V2.1 01-10-97 by Olly Koenders (A.R.G BBS +61-3-9870-4608 In Oz) Below are the docs for V2.0, which had a slight code malfunction that caused DoubleTake to read AmiFileSafe and FFS directory cached disks incorrectly. Why? Unknown really. But rest-assured it now works on all DosTypes, Kickstarts and Processors etc. Some code has been optimized and memory handling is better. Many thanks to Hans de Groot (hansg@3wis.nl) for bringing this to my attention as soon as it appeared on Aminet. Sorry fellas, didn't have AFS or anything with directory caching to test on when I was with KS 1.3 (yeah..), and now it should also work with FastSmoothDirs (old proggy)! Anyhoo - enjoy! Olly :) <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><> ... ... ...address changed from V2.0 docs! ... ... Why V2.0? Well, it started something like this... Brother: "Excuse me Mister `Expert Programmer'..." Me: "Eh?" (Here we go - Another Chrissy wish-list taped to the fridge!) Brother: "I need a program that will find all the doubled-up files an' stuff on me hard disk." (New A4000T with 1.2 Giggles o' stuff) Me: "Uh." (Shit! - old A500 with WB 1.3 and still scratching floppies because I never needed to upgrade) Brother: "'Cos I found a few files that were doubled-up in different directories an' I reckon there'd be HEAPS more layin' around wastin' space..." (Space?!? - What?!?) Me: "Yyyyyyyehhh... Umm... I could access the filenames using DOS an' then hash 'em around a bit... This might need some lengthy experimentation..." Meanwhile `Brother dearest' leaves me to ponder said intricacies and, appearing to be satisfied with his inspirational address, goes back to his `Playstation' to continue cursing at an unspecified application that "...won't @#?*&! handle @#?*&! brushmaps properly!!!". Complaints I reckon are unfounded considering he got the thing from a coverdisk. While fumbling around trying to put out a fire somewhere in my overstuffed ashtray, I was thinking that this shouldn't be too hard... The rest of this story can be found in the `TECHIE SECTION' if required. **** NON-TECHIE SECTION **** The above gives a basic outline of its purpose. The results can be well worth it or not depending on the number of useless duplicate files/libraries etc. - Considering the 17000-odd file & directory names dragged from the abovementioned machine (not to mention the hundreds of duplicates!). To get it running, click its icon from WorkBench or enter its name in the CLI, then click on one of the appropriate buttons. Time to completion will be dependant on the amount of stuff contained on the device, the level of directory fragmentation, whether its a floppy or HD and also the speed of your computer. DoubleTake first searches the entire selected device, retrieves all the file and directory names and writes each entry name to `RAM:DirList'. There's enough memory allocated to go 30 directory levels deep (Assembler:/devs/printers/etc./etc.) so if you have a directory with 31 entries behind it then either you're really dumb and like wasting 512 bytes every time you `Makedir' another one or you try to be too organised - Get over it! Pass 1 sorts them into some logical order deeming which files belong in what directory etc. This is necessary due to the DOS exnext() function returning the next FileInfoBlock that's chained to the previous block which could belong to either a file or directory. All directory programs attempt to sort their directory output if specified, and that's exactly what they have to stumble through, albeit this one isn't done alphabetically. During sorting, each entry is written back to the file `RAM:Dirlist' which is necessary for the next function but not deleted so the user can do with this file as they please. This file (somewhat shorter than the first) is then loaded back into the same allocated memoryblock and Pass 2 begins where the duplicate files are matched in their respective directories and output in `RAM:Multilist' (Which is the free gift you should be most interested in and is yours to keep whether you return the Ginsu Salami Slicer or not...). Note that this was about the easiest way I could devise to get the results and also create the Dirlist which can have its uses (Quick! - Think of something! ...Anything!). Although Norton Utilities for the PC have something similar and is probably many, MANY killerbytes huge, it's bloody useless on the Amiga. Besides that, So far I've not seen any program that does this on the Amiga but I'm sure there are a few. Some might even be found in applications such as `Pagesetter' or even large and specialised database programs. But buying a massive (read expensive) application for this small but handy purpose doesn't have many merits apart from some of the extra options that may be available, like Datestamping, Comments or filesize output. You don't get much for nothing (usually even less) - version 1.0 was Shell use only, and the first version that worked fully from start to finish with its original purpose in mind. During its construction, many (Well - about a hundred) versions were built and tested just to get the damn thing to work (All this kind of stuff is very new to me). If I named it version 107.24, even I'd pass it by with scant regard (Remember Cache's X-Copy and the plethora of versions following it?). Version 1.0 was far from satisfactorily complete so a user interface was implemented. When in operation, the numbers you see are vital to the internal workings of the program but also serve as a good progress indicator. With the Amiga and IBM (Idiot Breed Mentality) world in a storm at the moment about the ubiquitous `Progress Indicator' where every damn application is thrusting this thing in our face, I thought I'd get my own back. DoubleTake is solid, fast and there are no real bugs. If a disk or device isn't accessible then this error will be detected and dealt with appropriately. If however a problem develops during the disk reading phase (Corrupt disk?) then the operating system will more than likely pipe up and tell you that something is really, REALLY wrong and either hang up or let you do it yourself. This won't cause any further damage to your disk though. While on the subject... **** DISCLAIMER **** I will not be held responsible for damage caused by DoubleTake under any circumstances (Blah, Blah, Blah...). Note that damage would be completely impossible due to the program only writing to the RAM: disk - unless you already have a file in RAM: called `Dirlist' (Gee-whiz! The shields are down to 17 percent AGAIN, Captain! I shoulda foreseen that fantastic probability...). The reading process will only damage a disk if you've been storing it in a sand pit or if you HAMMER THE BLOODY THING INTO THE DRIVE UPSIDE DOWN! **** FREE GIFT! * FREE GIFT! * FREE GIFT! * FREE GIFT! * FREE GIFT! **** The icon is free. This program and its associated files (This one and the icon) are free. This program and its associated files may be distributed anywhere on anything in any usable form including Belfast, Norway, Russia and UpperKumbucta West if so desired because this program and its associated files - are free. A small donation wouldn't hurt though... Enjoy. **** TECHIE SECTION **** ... Anyway - four days, many headaches, some (almost) sleepless nights, an incalculable number of coffees and a couple slices of cheese later... Here 'tis! - Sorta. At the time, the only way I was able to get the entire directory of a disk was to use the original `c/Dir' command and type the string: dir >ram:dirlist