RFR: JDK-8325441: IGV: update pom.xml such that IntelliJ can import as maven project [v2]
Christian Hagedorn
chagedorn at openjdk.org
Tue Feb 20 15:52:58 UTC 2024
On Sun, 18 Feb 2024 08:59:07 GMT, Tobias Holenstein <tholenstein at openjdk.org> wrote:
>> Currently IntelliJ does not import the pom.xml correctly:
>> - Java version in Module settings is not correct
>> - The the source roots (src/main/java) are not set correctly
>> - the pom.xml shows formating errors in IntelliJ
>>
>> This PR fixes the pom.xml that it can be imported directly into an IDE as a modular maven project
>>
>> ### Intellij
>> Open IGV in Intellij:
>> 1. "Open..." -> `src/utils/IdealGraphVisualizer/pom.xml` -> "Open as Project"
>> - Right-click `IdealGraphVisualizer` -> "Open Module Settings"
>> - Add Modules should be imported with the following settings
>> - Langauge Level: `17`
>> - Source Folders: `src/main/java`
>> - Resource Folders: `src/main/resources`
>> - Excluded Folders: `target`
>> <img width="364" alt="modules" src="https://github.com/openjdk/jdk/assets/71546117/365cd355-5c51-44e7-a7fa-6fc36c983073">
>>
>> 2. "Add New Configuration" -> "Maven"
>> - Run: `--batch-mode nbm:run-platform -f application/pom.xml`
>> - "Modify options" -> "Add before launch task" -> `clean install`
>> - Java Options: choose a RFE version 17 - 21
>> <img width="921" alt="config" src="https://github.com/openjdk/jdk/assets/71546117/a272ef2e-e243-4d79-8ae2-ed6feb62fc96">
>>
>> 3. Run the configuration to start IGV
>>
>> ### NetBeans IDE
>> 1. Open Project -> `src/utils/IdealGraphVisualizer`
>> 2. Right-click on `IdealGraphVisualizer-app` -> "Run"
>> 3. IGV should start up
>>
>> ### Eclipse
>> 1. "File" -> "Import..." -> "Maven" -> "Existing Maven Projects"
>> 2. All modules should be imported
>> 3. Right-click on `IdealGraphVisualizer-parent/pom.xml` -> "Run As" -> "Maven install"
>> 4. Right-click on `IdealGraphVisualizer-parent/pom.xml` -> "Run As" -> "Maven build..."
>> - Goals: `--batch-mode nbm:run-platform -f application/pom.xml`
>> - Run
>
> Tobias Holenstein has updated the pull request incrementally with one additional commit since the last revision:
>
> remove import org.w3c.dom.DOMImplementation;
Looks good! Tested it with IntelliJ and works as expected.
-------------
Marked as reviewed by chagedorn (Reviewer).
PR Review: https://git.openjdk.org/jdk/pull/17754#pullrequestreview-1890800153
More information about the hotspot-compiler-dev
mailing list