eclipse:eclipse_ide
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
eclipse:eclipse_ide [2015/11/10 11:20] – [IDE Plugins] skip | eclipse:eclipse_ide [2023/11/01 07:15] (current) – ↷ Page moved from camunda:eclipse:eclipse_ide to eclipse:eclipse_ide skipidar | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ===== Eclipse IDE ===== | ||
+ | ==== Run configuration ==== | ||
+ | **Menu > Run > Run Configurations** \\ | ||
+ | Details are [[http:// | ||
+ | |||
+ | {{http:// | ||
+ | |||
+ | |||
+ | ^ Concept ^ Tab ^ Explanation ^ | ||
+ | | Workspace Data | Main Tab \\ {{http:// | ||
+ | | Launch configurations| Configuration Tab \\ {{http:// | ||
+ | |Java and Project execution-arguments| Arguments Tab \\ {{http:// | ||
+ | |||
+ | ==== Path Variables ==== | ||
+ | The [[http:// | ||
+ | |||
+ | E.g. to point to a imported Eclipse project - use the syntax: | ||
+ | |||
+ | ^Var ^Path^ | ||
+ | |${project_loc: | ||
+ | |${workspace_loc} |c: | ||
+ | |${workspace_loc:/ | ||
+ | |${workspace_loc:/ | ||
+ | |${project_loc} |c: | ||
+ | |${project_loc:/ | ||
+ | |${container_loc} |c: | ||
+ | |${resource_loc} |c: | ||
+ | |${project_path} |/ | ||
+ | |${container_path} |/ | ||
+ | |${resource_path} |/ | ||
+ | |${project_name} |MyProject2| | ||
+ | |${container_name} |MyFolder| | ||
+ | |${resource_name} |MyFile.txt| | ||
+ | |${build_type} |none| | ||
+ | |||
+ | |||
+ | After the ":" | ||
+ | |||
+ | <fc # | ||
+ | |||
+ | How to inspect the eclipse path-variables: | ||
+ | * Use **Run > External Tools > External Tools Configurations** | ||
+ | * Add **C: | ||
+ | * Run and see in console which path was used | ||
+ | |||
+ | {{http:// | ||
+ | ==== Exclude packages from organize imports ==== | ||
+ | To exclude packages from automatic import functinality add it here: | ||
+ | {{http:// | ||
+ | |||
+ | |||
+ | ==== Shortcuts ==== | ||
+ | |||
+ | ^ShortCut ^Describtion^ | ||
+ | |STRG + Alt + H (cursor in Method or Class)| Shows the Call hierarchy. Bottom Up. \\ Shows endless path from current class / method to the callers, to the callers of callers... | | ||
+ | |STRG + Shift + G (cursor in Method or Class)| Shows where the current class/ | ||
+ | |||
+ | ==== Subversive uninstall ==== | ||
+ | The only way to delete this fucking peace of shit is by deleting jars: | ||
+ | < | ||
+ | org.eclipse.team.svn.core_0.7.5.I20081029-1900.jar | ||
+ | org.eclipse.team.svn.help_0.7.5.I20081029-1900.jar | ||
+ | org.eclipse.team.svn.resource.ignore.rules.jdt_0.7.5.I20081029-1900.jar | ||
+ | org.eclipse.team.svn.ui_0.7.5.I20081029-1900.jar | ||
+ | org.eclipse.team.svn_0.7.5.I20081029-1900.jar | ||
+ | org.polarion.eclipse.team.svn.connector.javahl15_2.0.5.I20081024-1200.jar | ||
+ | org.polarion.eclipse.team.svn.connector.javahl_2.0.5.I20081024-1200.jar | ||
+ | org.polarion.eclipse.team.svn.connector.svnkit15_2.0.5.I20081024-1200.jar | ||
+ | org.polarion.eclipse.team.svn.connector.svnkit_2.0.5.I20081024-1200.jar | ||
+ | org.polarion.eclipse.team.svn.connector_2.0.5.I20081024-1200.jar | ||
+ | </ | ||
+ | |||
+ | |||
+ | ==== Static builder ==== | ||
+ | The static builder are **Eclipse project specific**. | ||
+ | The static Builders are responsible for static code analysis, as described [[http:// | ||
+ | * Maven | ||
+ | * Warnings | ||
+ | * API deprecation | ||
+ | * Checkstyle... | ||
+ | |||
+ | {{http:// | ||
+ | |||
+ | |||
+ | ==== Define own templates ==== | ||
+ | |||
+ | You can use variables to position the cursor, to retrieve the package or class! | ||
+ | Then a static Logger can be retrieved by one line, incl. package names and imports! | ||
+ | A good usage example is: | ||
+ | < | ||
+ | private static final org.slf4j.Logger LOG = org.slf4j.LoggerFactory.getLogger(${enclosing_type}.class); | ||
+ | </ | ||
+ | |||
+ | Own Templates can be defined by using Editor Templates: | ||
+ | {{http:// | ||
+ | |||
+ | After that you will be able to do actions, which you do frequently, by typing ALT + < | ||
+ | {{http:// | ||
+ | |||
+ | ==== Eclipse Metafiles ==== | ||
+ | |||
+ | == .project == | ||
+ | Describes the project Data, like Name etc. | ||
+ | < | ||
+ | <?xml version=" | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | == .classpath == | ||
+ | |||
+ | |||
+ | |||
+ | ==== Eclipse Maven Tycho Plugin ==== | ||
+ | |||
+ | This Plugin allows automatic reading of maven configuration files (pom.xml), \\ | ||
+ | extracting dependencies from these files, \\ | ||
+ | importing them as Eclipse dependencies! | ||
+ | |||
+ | == Resolution of Dependencies in Workspace == | ||
+ | Maven can look for open Projects in Workspace and resolve Project resolutions by using open Porjects from workspace. | ||
+ | |||
+ | < | ||
+ | |||
+ | == Offline build == | ||
+ | If you wanna run a job, \\ | ||
+ | so that the build only depends on artefacts in LOCAL REPOSITORY \\ (Maven should not download stuff from remote repository, maybe because you are developing something locally and did not check in changes yet. So you build a project part and put it into you local repo. And another project part depends on it, so you only rebuild this part. So Maven should use artifacts from local repository, which were changed earlier but not checked in! ) | ||
+ | |||
+ | Todo that - check the offline checkbox in the matching **runtime configurations**! | ||
+ | |||
+ | {{http:// | ||
+ | |||
+ | |||
+ | |||
+ | ==== Static code analyzer ==== | ||
+ | |||
+ | There are: | ||
+ | * Checkstyle - http:// | ||
+ | * PMD - http:// | ||
+ | * FindBugs - http:// | ||
+ | |||
+ | == CheckStyle == | ||
+ | Fast applying correcting the checkstyle rules is able by doing following on the Error. < | ||
+ | **DOES NOT WORK IN KEPLER:** Mass Checkstyle QuickFixes: < | ||
+ | |||
+ | {{http:// | ||
+ | {{http:// | ||
+ | |||
+ | ==== Debugging Source lookup ==== | ||
+ | The Debugging Source lookup should always be a Project, if possible. (Not a Jar, not a Folder) \\ | ||
+ | This enalbes setting breakpoints, | ||
+ | |||
+ | To change the existing Debugging Source change to the Debugeer perspective, | ||
+ | {{http:// | ||
+ | |||
+ | |||
+ | ==== GC overhead limit exceeded ==== | ||
+ | Let Eclipse use more memory, so that it does not regulary get " | ||
+ | |||
+ | - Open **eclipse.ini** | ||
+ | - Replace numers 256 by 1024 or even 2048 < | ||
+ | |||
+ | -startup | ||
+ | plugins/ | ||
+ | --launcher.library | ||
+ | plugins/ | ||
+ | -product | ||
+ | org.eclipse.epp.package.rcp.product | ||
+ | --launcher.defaultAction | ||
+ | openFile | ||
+ | --launcher.XXMaxPermSize | ||
+ | 2048M | ||
+ | -showsplash | ||
+ | org.eclipse.platform | ||
+ | --launcher.XXMaxPermSize | ||
+ | 2048m | ||
+ | --launcher.defaultAction | ||
+ | openFile | ||
+ | --launcher.appendVmargs | ||
+ | -vm | ||
+ | d:/ | ||
+ | -vmargs | ||
+ | -Dosgi.requiredJavaVersion=1.6 | ||
+ | -Xms40m | ||
+ | -Xmx512m | ||
+ | |||
+ | </ | ||
+ | |||
+ | |||
+ | ==== Pointing to a specific JDK ==== | ||
+ | < | ||
+ | -vm | ||
+ | d:/ | ||
+ | </ | ||
+ | |||
+ | |||
+ | ==== M2E ==== | ||
+ | |||
+ | Ein Plugin welches viele Maven Befehle in Eclipse einbaut. | ||
+ | |||
+ | Um aktualisierte Maven-Artefakte wieder via Maven Repository zu beziehen macht man: | ||
+ | < | ||
+ | |||
+ | {{http:// | ||
+ | |||
+ | Alternativ kann man dasselbe auch via Console machen. Generiert .project und .pref Dateien. | ||
+ | http:// | ||
+ | < | ||
+ | mvn eclipse: | ||
+ | </ | ||
+ | |||
+ | |||
+ | ==== IDE Plugins ==== | ||
+ | |||
+ | |Grep Console|coloring in console| https:// | ||
+ | |ObjectAid UML Explorer| UML generation from code| https:// | ||
+ | | Eclipse Tooling | All Spies and E4 Tools |< | ||
+ | - https:// | ||
+ | - https:// | ||
+ | - https:// | ||
+ | - https:// | ||
+ | - https:// | ||
+ | </ | ||
+ | |Jspresso Colors 'n Fonts| Tool to visualize Colors / Fonts directly in Eclipse|http:// | ||
+ | |PDE Visualization Plugin| adds Graph Plug-in Dependencies View | https:// | ||
+ | |Properties Editor|Properties Editor which can visualize escaped chars and unicode chars|https:// | ||
+ | |||
+ | ==== out-of-sync with filessystem problems ==== | ||
+ | |||
+ | To make Eclipse sync automatically with files system - let it poll the folders automatically | ||
+ | |||
+ | < | ||
+ | Windows > Preferences > General > Refresh using native hooks or polling | ||
+ | </ | ||
+ | |||
+ | {{http:// |