Paths and sizes

The top of the document window provides information about paths you can use to refer to the item, and its size.

At the top is the full path to the item, and below that are the two other methods of giving its path, using the volfs system, and as a FileReferenceURL . The volfs path to the file uses its inode data to provide a reference to the file which is more enduring than its normal path and name. Simply copy that to Terminal if you want to use it in a command there.

Precize calculates seven different measures of its file size, according to two different methods.

The sizes given in the row labelled URL Keys are calculated using two URLResourceKeys, giving the basic size (Data only), and the total size (Total, which “includes metadata”). From those, the size of the metadata is calculated.

The sizes given in the row labelled File system are calculated using File Manager FileAttributeKeys (for Data), and the getxattr function (for Metadata), then they are added to return the total size of the selected file.

The two measures in the Data column should be identical, and correspond with that reported in the Finder, the ls command in Terminal, and everything else in MacOS. However, they ignore xattrs completely.

The two measures in the Metadata column should also be identical, and should match the total of individual metadata for that file. In practice, they usually don’t.

The two measures in the Total column should also match, but if the file has xattrs, they usually don’t, with that from URL Keys normally being less than that from the File system.

The size given for Disk is the disk space currently allocated to the file’s data. In normal circumstances, this will be slightly larger than the Data size, rounded up to the next whole storage block. However, it will be far smaller in the event that the file is being stored as an APFS Sparse File.

When you need to know the accurate and complete total file size, for example as will be used on a USB memory stick formatted using ExFAT, the most accurate value is that at the bottom right, for the Total given by the File system.

➜ permission and dates

➜ referencing files and folders

➜ details

➜ welcome

The Eclectic Light Company – https://eclecticlight.co