-
Notifications
You must be signed in to change notification settings - Fork 300
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
Plugin fails with git submodule involved #701
Comments
Thanks for the ticket and the reproducer. Will try to troubleshoot on the weekend. Unclear how difficult it would be to fix it, so i can't provide any ETA at this time. |
@TheSnoozer Thank you for your quick answer and for the time you will take to look at it. I understand it seems like a tricky one, just don't hesitate to ping me back if you need more details regarding our project and issue ! |
Again thanks for the detailed explanation and the ability to reproduce! I did a "quick" troubleshooting session and it indeed seems that the lookupGitDirectory function in the GitCommitIdMojo is somewhat to blame here. running your project with
When surrounding this lookupGitDirectory with print statements it would tell us:
The issue you linked in fact only added a fix for
I guess all that means we would need a |
Very detailed explanation, thanks for taking a look at this :) |
I took another look and created various tests to verify my hypothosis (mainly wanting to ensure that the bug is actually fixed). After the second round of "quick" troubleshooting where I now also run the commands manually I think the gitDirectory of
I think what mainly threw me off is that the tests i have performed indicated that this issue only happens when running with Setting a it took me way to long to realize that this may be a very very very very old oversight in running the NativeGit: Here we run unconditionally I guess when running native git commands assuming that we need to go to the parent-dir makes a lot of sense:
However I guess what this now means is that we need to |
…ry with remote submodules
#701: add testcases to for an issue with submodules
git-commit-id/git-commit-id-maven-plugin#701: Fix an issue with submodules
Once again very detailed explanation ! Thanks for taking the time to fix this, very appreciated :) Let us know when you do a new release including this fix @TheSnoozer ! Cheers |
Thanks again, released now: https://repo1.maven.org/maven2/io/github/git-commit-id/git-commit-id-maven-plugin/8.0.0/ Please check the release notes why this is now a breaking change (https://github.com/git-commit-id/git-commit-id-maven-plugin/releases/tag/v8.0.0) |
Alright I will test that out, thanks @TheSnoozer :) |
Describe the bug (required)
The community in Apache James project (https://github.com/apache/james-project) upgrade recently this plugin from version 4.9.10 to 7.0.0 : apache/james-project@88e1ae8
For the TMail backend project using Apache james as a submodule to implement extra features on top, it creates the following issue when trying to upgrade our project to latest version of the submodule:
PR: linagora/tmail-backend#932
It seems similar to this issue: #639 that has been solved and merged into 7.0.0 it seems (cf #642).
Except that I actually never really used worktrees in the first place? Is there some conflict perhaps?
Tell us about your plugin configuration (required)
It comes from the Apache James project that is used as a submodule into TMail project
Tell us about the Plugin version used (required)
7.0.0
Tell us about the Maven version used (required)
Steps to Reproduce (required)
Are there any stacktraces or any error messages? (required)
Is there a (public) project where this issue can be reproduced? (optional)
https://github.com/Arsnael/tmail-backend
Your Environment (optional)
git version 2.43.1
Context (optional)
No response
The text was updated successfully, but these errors were encountered: