-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Parent folder of files to package is now included in tar #535
Comments
That's a known issue. DART tries to trim off the common prefix of all the folders you bag. For example, DART will trim
But if you add one more directory, like I think tar and zip have similar behavior. I'm not sure how thoroughly this behavior is documented for DART, but path trimming was widely requested after DART's initial release. |
Thank you for that great explanation, just confirmed it there by having a single folder input and all was well. Is this fixable or is it too baked into how tarring works? |
I don't see any easy fix for this. When DART wasn't trimming paths, everyone complained. So the feature is in there by popular demand. If I turn it off, then every item in the payload directory has a path like With path trimming on, there's no safe way to guess how to trim paths that have no common prefix. |
I get you, I looked into it a bit more and can see why this is so awkward. I'm not that familiar with more complex tar use cases like this. |
I would be reluctant to implement something like that, because I don't have much time and because it could make DART more confusing / harder to use. Part of its appeal is its simplicity and easy learning curve. In case you're interested, when you get to the "Review and Run" screen, DART shows the part of the file paths that will be trimmed off in grey, while the rest of the path is in black. In the screenshot below, |
I'm using 2.0.21 on Win10.
I have two inputs - a single file and a folder which contains three files.
C:\Users\NLI User\Documents\complex_objects_workshop.docx
C:\Users\NLI User\Downloads\strongbox_fixity_fail
I then make a tarred bag, but I see that in the TAR, the 'Documents' and 'Downloads' folders are also present even though my inputs were children of these folders. This issue does not occur if I just make a regular bag that is not tarred.
The text was updated successfully, but these errors were encountered: