Closed ahus1 closed 3 months ago
The only way to include authorship when squashing across authors in including this in the trailers, that's what you see in the Co-authored-by
.
Using Co-authored-by
would be great, and this would be my expectations. Still, this information is gradually removed on every push. Looking at the example above, the first commit has Co-authored-by: Alexander Schwartz <alexander.schwartz@gmx.net>
, which is then removed on the following push to the same PR. This is unexpected.
Ah, the issues is that these are missing in https://github.com/keycloak/keycloak/commit/1a3ddc96aafdcbc2e7b75c4f13595d4db38bc4a6. It appears that Weblate was unable to correctly assign this to existing translation and committed that as leftover files here:
I think this is caused by the add-on being executed with a linked component and not the main one because of project-wide install and that should be fixed.
Something like 8c66d1d6bba will be needed for this event (or generalize the solution for repository scoped add-ons).
Thank you for your report; the issue you have reported has just been fixed.
Thank you for this fix. To try it out on the hosted service on weblate.org, I assume I'll need to wait for Weblate 5.7 to be released and then installed on weblate.org?
Waiting is ok for me, I just need to know when to try it out. In the meantime, I've subscribed to the releases of this repository to get a notification upon release.
AFAIK it should be already deployed on Hosted Weblate.
Describe the issue
I want to have one commit per language, and keep the authors. The docs gave me the impression that this should be possible (emphasis added by me):
I didn't find documentation on how to create a commit message that can be customized to include multiple authors, so I left it blank, hoping for the best as "Append trailers to squashed commit message" was enabled.
No luck here - I now only get a generic message "Updated by "Squash Git commits" hook in Weblate.", but only on the second time I trigger the push to the target repository.
I already tried
Steps to reproduce the behavior
Expected behavior
As both commits changed the same language but different components, I would have expected to see only one commit.
As I check the "append trailers", I expected the authors to be kept.
Screenshots
No response
Exception traceback
No response
How do you run Weblate?
weblate.org service
Weblate versions
No response
Weblate deploy checks
No response
Additional context
Looking at the code of the extension, it seems to me that there is some very different handling for the per-author setup - https://github.com/WeblateOrg/weblate/blob/main/weblate/addons/git.py.
As I fallback, I am reverting to the "per author" commit squashing, which works better for me, although I would still like to see one commit per language that then lists all the authors that contributed to it.
For me the one-commit-per-language would be the input for some follow-up processing of having one-PR-per-language as described in #5563
If the way I'm trying to use it is not the way it is intended to be used, I'd be happy to see a docs change. It would be great to understand how a template for "Original commit messages are kept [if] the commit message is customized to include it" would work, together with "Append trailers to squashed commit message".