-
Notifications
You must be signed in to change notification settings - Fork 0
DSKTOOL
DSKTOOL is a command line program used to examine, extract files from and insert files into einstein DSK images.
It is pre-built for mac and windows, linux users can build from source. Ignore the VS stuff, it's plain c++17.
Usage: dsktool [command] path-to-dsk-file
Where command looks like one of:
- dir
- extract * (to path-to-directory)
- extract filename (to path-to-directory)
- insert path-to-file
- insert path-to-directory
- dumpdos path-to-file
Let's go over these one-by-one.
As you might expect, the dir command yields a list of files on the disk.
$ ./dsktool dir chuckie.dsk
If you want to pull a file from the disk image, or indeed pull all the files from it, then use one of the following commands.
$ ./dsktool extract chuckie.com chuckie.dsk
$ ./dsktool extract * path/to/chuckie.dsk
If you want the files to go somewhere else, use the 'to' modifier.
$ ./dsktool extract chuckie.com to ~/emulation/einstein/games ~/emulation/einstein/dsk/chuckie.dsk
$ ./dsktool extract * to comfiles ~/emulation/einstein/dsk/chuckie.dsk
Insert a file into the image if possible. There are some restrictions on file names of files to insert. Make sure the files are named according to the 8.3 standard. 'THISIS.OK' 'THISISNOT.OK' 'NEITHER IS.THS'. No checks are made for duplicate file names. Unknown things will happen if multiple files with the same name are present in an image.
$ ./dsktool insert myfile.xyz myspecial.dsk
If the path names a folder, all the files within that folder will be added if possible.
$ ./dsktool insert emu/einy/applications myspecial.dsk
Dumps the content of the first 2 tracks, 20 sectors, into the named file. This will be useful in future for generating disk images from fresh. For now it enables you to examine the dos, or whatever. It'll be useful sometime when I add the writedos command..!
Caveat emptor! It is early days and there is very little error checking. Modifications to dsk files are permanent, there is no undo. Work on copies. Proper preparation prevents poor performance.
todo
- error checking
- filename cleansing
- rejection of incompatibly named insert files? or just replace?
- create dsk image from scratch
- no need for 'donor' disk for DOS