Skip to content
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

Keep external annotations paths when updating the project configuration (fixes #391) #1635

Merged
merged 1 commit into from
Feb 3, 2024

Conversation

sebthom
Copy link
Contributor

@sebthom sebthom commented Dec 27, 2023

Prior to this commit, the manually configured external annotation paths for the "JRE System Library" and "Maven Dependencies" classpath entries of an m2e managed Eclipse project were being unset when m2e updated the Eclipse project configuration, e.g. due to changes in the underlying Maven project or due to manual execution of "Maven -> Update project...".

This commit ensures that the external annotation path settings are still present after m2e updated the Eclipse project configuration.

image

Fixes #391

@sebthom sebthom force-pushed the external-anno branch 2 times, most recently from c1f8483 to ba7b66c Compare December 27, 2023 13:13
@laeubi
Copy link
Member

laeubi commented Dec 30, 2023

@sebthom can you squash your commits and add a commit message that described the current and improved state?

Copy link

github-actions bot commented Dec 30, 2023

Test Results

  214 files  ±0    214 suites  ±0   16m 36s ⏱️ -36s
  664 tests ±0    654 ✅ ±0  10 💤 ±0  0 ❌ ±0 
1 328 runs  ±0  1 306 ✅ ±0  22 💤 ±0  0 ❌ ±0 

Results for commit 9c9704d. ± Comparison against base commit d4d77aa.

♻️ This comment has been updated with latest results.

@sebthom
Copy link
Contributor Author

sebthom commented Dec 30, 2023

@laeubi done

@sebthom
Copy link
Contributor Author

sebthom commented Jan 19, 2024

@HannesWell @laeubi I would greatly appreciate it if this could be included in the next m2e release. 🤞

Prior to this commit, the manually configured external annotation paths
for the "JRE System Library" and "Maven Dependencies" classpath entries
of an m2e managed Eclipse project were being unset when m2e updated the
Eclipse project configuration, e.g. due to changes in the underlying
Maven project or due to manual execution of "Maven -> Update
project...".

This commit ensures that the external annotation path settings are still
present after m2e updated the Eclipse project configuration.

Fixes eclipse-m2e#391
Copy link
Contributor

@HannesWell HannesWell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sebthom thank you for this contribution, it looks good.
I just reworked it a bit to reduce code-duplication and to stream-line the creation of new classpath-entries, but the behavior should be the same (as your tests shows).

Btw. if you are concerned about changes in the configuration due to automated updates, the PR #1664 might be interesting for you.

@HannesWell HannesWell changed the title fix: updating project config removes external annotations path #391 Keep external annotations paths when updating the project configuration (fixes #391) Feb 3, 2024
@sebthom
Copy link
Contributor Author

sebthom commented Feb 3, 2024

@HannesWell Looks good to me. Thanks for reviewing/updating!

@HannesWell
Copy link
Contributor

@HannesWell Looks good to me. Thanks for reviewing/updating!

Great. Thanks for the fast feedback.
All builds are green, submitting.

@HannesWell HannesWell merged commit 3aa12f5 into eclipse-m2e:master Feb 3, 2024
7 checks passed
@HannesWell HannesWell added this to the 2.6.0 milestone Feb 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update Project removes custom classpath entries
3 participants