Live data from Hacker News

Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

aruljohn.com

91–100 of 109 posts

Re: Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

#91
post #11

Earlier quoted context omitted.

It's a good attitude to have, in my opinion. Portability is overrated. Linux developers should be doing a lot more of this. We should be making everything work better for us without caring how it's going to impact other irrelevant platforms. Let the people who actually care about those platforms worry about such things.

It would at least be nice if there was a way to keep apple users from shitting all over the filesystem with remote mounts and ds_store files. Perhaps by automatically unmounting if one is detected.

At least with Samba you can use the "veto files" and "delete veto files" global directives to deal with those, I personally use the following for veto files:

    /._*/.AppleDB/.AppleDouble/.AppleDesktop/:2eDS_Store/Network Trash Folder/Temporary Items/TheVolumeSettingsFolder/.@__thumb/.@__desc/:2e*/.@__qini/.Qsync/.@upload_cache/.qsync/.qsync_sn/.@qsys/.digest/
I understand that I may loose resource forks, but that isn't a problem for the use case of my server.

Re: Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

#92
"For some reason" there are ._ files... now I'm really feeling old, that an apparently-savvy macOS user seems to be unaware of the history of resource forks and AppleDouble. That was fundamental knowledge in the subject of Mac/PC interchange not terribly long ago.

Re: Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

#94

Earlier quoted context omitted.

Agreed. Where else would you put that stuff? It’s gotta go somewhere, and this is the least surprising place IMO. Anywhere else would have to be a parallel store that follows filesystem mounts and unmounts, renaming directories, etc so that it alway perfectly mirrors the thing it’s configuring.

> Where else would you put that stuff? A "Centralized thumbnail cache" in the user profile folder, where it's been for a long while. https://en.wikipedia.org/wiki/Windows_thumbnail_cache > so that it alway perfectly mirrors Who cares? It's a cache.

That windows takes an approach does not mean it’s a good idea.

And what about things like folder settings, such as whether to display is as a list or as icons, or how to sort it, etc? That’s more important than a thumbnail cache.

Re: Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

#95

Would this ever affect me if I don't use many of MacOS built on tools? I brew install gnu equivalents make them all default. Just like how I also don't use most of their desktop environment stuff, and instead use rectangle, hammerspoon, karabiner to make it feel more like the Linux desktop I wish I could use at work.

Mostly yes. If `tar` resolves to gtar in your PATH, your archives won't carry the LIBARCHIVE.* xattrs that GNU tar can't decode, so the warnings go away.

One thing that still trips me up though: `._Foo.txt` AppleDouble files get created in your filesystem any time something Finder-adjacent touches a folder, and gtar archives them just fine, but they show up as garbage on the Linux side. `dot_clean -m mydir/` before tarring kills them, or you can pipe through `--exclude='._*'` if you don't want to touch the source tree.

Re: Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

#96
post #33

Earlier quoted context omitted.

OTOH, If you want the information contained in those files, where else would you save it?

To me it seems more sensible to store information relevant only to this OS in a specific cache somewhere within that OS. It would even make cache-like functionality such as evicting old entries super easy.

> sensible to store information relevant only to this OS in a specific cache somewhere within that OS.

For most of these files, this isn’t information that can be reconstructed, so caching isn’t an option.

Also, the information has to move with the disk, if it is moved to or mounted on another system.

Re: Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

#98
post #67

Earlier quoted context omitted.

There are some tradeoffs. Like if you used a usb and set up folder colours or any of the other things stored in the file, they would not move along with the usb when used on another computer.

If I set a folder colour in Finder on my work MacBook, and then plug that USB drive into my personal computer which uses Thunar as a file browser on Debian, nothing would happen.

And? If you mount a Unix file system on another system, you may see ‘invisible’ fuels whose name starts with a period, may even see weird files named “.” or “..”, may not see ACLs, and may not see any file attributes such as user and group information.

In 1970 it already was not true that one could treat all filesystems the way Unix did, but it certainly isn’t true anymore today.

Re: Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

#99

"For some reason" there are ._ files... now I'm really feeling old, that an apparently-savvy macOS user seems to be unaware of the history of resource forks and AppleDouble. That was fundamental knowledge in the subject of Mac/PC interchange not terribly long ago.

I remember when creating a zip file from the finder filled it with a bunch of resource fork files that confused the hell out of anyone opening it on windows.

Re: Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

#100
post #20

Earlier quoted context omitted.

Nixos has a pretty solid solution to this issue: key your dependencies with checksums of the content. That way you get the best of both worlds: you always get the exact version you want, and you can share a copy of that exact version with other software that wants to use that exact version too!

So it sounds like you don’t get the exact version you want because metadata is thrown away.

Curious, what is your software doing that it depends on specific metadata in your dependencies? What metadata do you require? Most files metadata is stuff like created timestamp, last edit timestamp, read/write/execute permissions..

I'm just trying to think of a case where metadata would be relevant in a dependency?

Post reply on HN