new hfstools command : hdisk?

Rob Leslie
Mon, 05 Aug 1996 01:15:35 -0400

> All in all I think I'm just confusing things, because hfstools are
> very useful as they are :) Maybe just a simple mechanism for
> displaying hfs partitions in an hfstools specific manner and hmounting
> a specific partition (rather than always the first partition) in an
> hfstools specific manner would be more appropriate.

For what it's worth, the following Perl code will read and display the
partition map of an Apple-partitioned disk. For each HFS partition, it also
displays the name of the volume contained therein. If this is useful, perhaps
I will roll some form of it into the hfsutils distribution.

It has always been possible to select an alternate HFS partition for hfsutils
by supplying the desired ordinal HFS partition number (if other than 1) to
`hmount'. (Note that this only counts HFS partitions; other partitions are
ignored by hfsutils when counting HFS partitions.)

At some point I would actually like to write a partitioning utility that
writes an Apple partition map; is this what you're really looking for, Nick?

Robert Leslie


die "Usage: $0 device-path\n" unless (@ARGV == 1);

($disk) = @ARGV;

format STDOUT_TOP =
 # Partition Type                HFS Volume Name                Start    Length