Add support for no parent directory inference (#832)#834
Add support for no parent directory inference (#832)#834aiuto merged 1 commit intobazelbuild:mainfrom
Conversation
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
|
This is a start, intended to solicit early feedback. Existing tests have been merely adapted. New tests have not been added. |
aiuto
left a comment
There was a problem hiding this comment.
I think create_parents should be an attribute of TarWriter. Then we set it once on creation instead of having to plumb the constant through on each call.
On the plus side, this makes the code cleaner.
A potential minus is that we can't have add_parents toggle per src to the tarball.
I don't think that is a needed, or even desired, ability. It would only marginally facilitate a sparse tar with a few added directories. You could simulate that easily by composing
tars or (perhaps) by having an option on pkg_files to auto-insert needed directories.
|
I agree and would have done what you suggested to start with had it been taken into account that the change subject was a Class. And no, I don't see an obvious use case for having fine-grained control of the subject behavior within a target. |
aiuto
left a comment
There was a problem hiding this comment.
I think this will do for tests.
Thanks for the fix.
Add feature as described in bazelbuild#832. RELNOTES: Automatic creation of parent directory specifications for paths with depth are prevented in pkg_tar archives.
My pleasure! |
Add feature as described in #832.
RELNOTES: Automatic creation of parent directory specifications for paths with depth are prevented in pkg_tar archives.