Open jamadden opened 1 year ago
Unfortunately, while the folder icons and positions show up correctly when accessed by macOS (Ventura) whether on a local disk or served over SMB, they do not show up in a classic MacOS 9.1 client when served over AFP via netatalk from the same volume that macOS Ventura was accessing them over SMB.
This turns out to be some difference in the way the SMB and AFP protocols are handling things. Copying to an AFP share from Ventura produces viewable icans when looked at from another AFP client, but not when looked at from an SMB client, and vice versa (copying to SMB looks fine to SMB clients, but not to AFP clients).
The
Folder
class has a "help me!" comment on the flags member: https://github.com/elliotnunn/machfs/blob/4f554286e6f5276a5b4d6d76f64fcecce31f1c26/machfs/directory.py#L337-L341I needed to get the flags to be able to properly export all the information from an HFS volume (like getting custom icons to show), so I searched for the information and captured the flags. Here's a diff giving that (sorry, I haven't had the time to work up a proper PR):
With that, I am able to use the following script on a macOS machine to export an HFS volume to a set of folders where the data and resource forks are preserved, as is the color label, position, and custom icons. Unfortunately, while the folder icons and positions show up correctly when accessed by macOS (Ventura) whether on a local disk or served over SMB, they do not show up in a classic MacOS 9.1 client when served over AFP via netatalk from the same volume that macOS Ventura was accessing them over SMB.