Closed Megakuul closed 4 months ago
@Megakuul In the docs it mentions that all patches are required to be in the -p1
format: https://github.com/bazel-contrib/publish-to-bcr?tab=readme-ov-file#including-patches. This is because the app will auto generate a version patch if the tagged version doesn't match the version in MODULE.bazel, and because all patches must have the same strip value I had to choose one arbitrarily.
I could avoid overriding the patch_strip when we don't auto-generate a patch. Alternatively, you could just alter the patch format?
I suppose I could also look at the format for any existing patches then generate a version patch in that format if needed :thinking:
@kormide sorry that's my bad, I absolutely overlooked the -p1
requirement. If it does not add too much complexity, I suppose it would be convenient for some projects to use a custom patch_strip
, however in my case, changing it to -p1
is straightforward.
When publish-to-bcr creates the pull request for the bcr, it sets the
patch_strip
attribute insource.json
to1
.I'm not sure if this is a bug or if I did something wrong right there. My
.bcr/source.template.json
file looks like this:In the automated PR, I then get this:
The
patch_strip
set to 1 does not work and it does not find the patch.Do you have any ideas why this behaves like that?