Your SlideShare is downloading. ×
0
Tips,	
  Tricks	
  &	
  Tools
every	
  Eclipse	
  User	
  should	
  know
• Project	
  Lead	
  of	
  Eclipse	
  Code	
  Recommenders
• Eclipse	
  Commi7er	
  since	
  2010
• Plug-­‐in	
  Developer...
supported	
  by
About	
  us
The	
  Knowledge	
  Transfer	
  Company
Disclaimer	
  ;-­‐)
Not	
  all	
  tools	
  I’m	
  talking	
  about	
  
today	
  are	
  free	
  or	
  open	
  source.
I	
  ...
If	
  you	
  don’t	
  know	
  your	
  keyboard	
  shortcuts...
No	
  Mouse!	
  #dcr13
⌘3
Quick	
  Access	
  –	
  ⌘3	
  
WHAT’S	
  NEW	
  IN	
  ECLIPSE	
  KEPLER?
Eclipse	
  Kepler	
  by	
  Numbers
(c)	
  Holger	
  Voormann	
  <eclipse@voormann.de>
New	
  and	
  Noteworthy
• Pla[orm	
  performance	
  improvements
• Pla[orm	
  builds	
  with	
  Eclipse	
  CBI
• IniXal	
...
REMEDIATION	
  SUPPORT	
  IN	
  ECLIPSE
Installing	
  new	
  features	
  can	
  be	
  painful...
Not	
  (that	
  much)	
  with	
  Eclipse’s	
  new	
  
Install	
  RemediaJon	
  Feature!
UPDATING	
  FROM	
  ECLIPSE	
  3.X	
  -­‐-­‐>	
  4.X
OMG,	
  I	
  don’t	
  want	
  to	
  reinstall	
  all	
  my	
  plugins...
Install	
  soQware	
  items	
  from	
  exisJng	
  installaJon...
Select	
  which	
  features	
  to	
  import...
Want	
  to	
  prepare	
  a	
  company	
  wide	
  install	
  file?
Export	
  soQware	
  items	
  w/	
  update	
  sites
EGIT/JGIT	
  3.0	
  
Git	
  in	
  Eclipse	
  -­‐	
  EGit	
  3.0
Rename	
  DetecJon
Reset	
  Repository	
  to	
  Expression
Clean	
  Repository
Commit	
  and	
  Push	
  (at	
  once)
GERRIT	
  &	
  MYLYN	
  REVIEWS
Four	
  eyes	
  can	
  see	
  more	
  than	
  two...
Gerrit	
  at	
  Eclipse
Reviewing	
  Changes	
  with	
  Gerrit
Gerrit	
  Workflow
Gerrit Hudson
Git
3.	
  Build2.	
  Pull
4.	
  Verified
6.	
  Push
7.	
  Pull
1.	
  Push
5.	
  Approve
HOW	
  IS	
  MYLYN	
  REVIEWS	
  GOING	
  TO	
  CHANGE	
  THIS?
1.	
  Push	
  and	
  Pull	
  to	
  Gerrit	
  from	
  your	
  IDE	
  
Feature	
  in	
  EGit
2.	
  Review	
  changes	
  in	
  your	
  IDE
3.	
  Submit	
  the	
  approved	
  change
4.	
  Get	
  noJficaJons	
  about	
  new	
  change-­‐sets
Mylyn	
  Builds
WHEN	
  EDITING	
  SOURCE	
  CODE
The	
  simple	
  basics...
Smart	
  Semicolons	
  &	
  Braces
Matching	
  Enclosing	
  Brackets
“Faster”	
  IntelliJ-­‐like	
  Code	
  CompleJon
.abcdefghijklmnopqrstuvwxyz
Favorites	
  for	
  import static
Type	
  Filters
WHEN	
  DEBUGGING	
  IN	
  ECLIPSE
The	
  hidden	
  and	
  rarely	
  used	
  jewels...
Step	
  Filtering
Debug	
  Details	
  Formamer
Debug	
  Logical	
  Structure
Extending	
  Logical	
  Structures
Extending	
  Logical	
  Structures
Heap	
  Walking
Eclipse	
  Memory	
  Analyzer	
  (MAT)
Drop	
  to	
  Frame
JRebel	
  Feature	
  Comparison	
  Matrix
Supported	
  Frameworks
Get	
  it	
  from	
  Eclipse	
  Marketplace
Test	
  Coverage	
  with	
  EclEmma
Test	
  Coverage	
  with	
  EclEmma
CODE	
  COMPLETIONS	
  IN	
  ECLIPSE
Smarter	
  than	
  I	
  expected...
Into	
  Code-­‐Comple`on	
  Wonderland
⌘1
Quick	
  Fix	
  –	
  ⌘1
⌘2
Quick	
  Assist	
  –	
  ⌘2
⌃	
  Space
Content	
  Assist	
  –	
  ⌃Space
⌃	
  .
SUBWORDS	
  COMPLETION
“BecauseCamelCaseMatching****s!”
Subwords	
  CompleJon
Install	
  Subwords	
  from	
  Eclipse	
  Marketplace
So	
  many	
  wonderful	
  engines?
"[In	
  Eclipse]	
  sort	
  by	
  relevance	
  is	
  synonymous	
  to	
  alphabe`cal.	
  
In	
  other	
  words	
  it	
  su...
@Override
protected Control createDialogArea(final Composite parent) {
Composite container = (Composite) super.createDialo...
All	
  164	
  proposals
	
  sorted	
  by	
  “Relevance”
What	
  Emanuel	
  wants...
Learning	
  Constructor	
  CompleJons
 Codetrails	
  Hippie	
  CompleJon
And	
  win	
  10	
  Raspberry	
  PIs!
How	
  about	
  IntelliJ	
  and	
  Netbeans?	
  Tweet!
Netbeans:
@geertjanw	
  Crowdsourced	
  Hippie	
  Comple`on	
  is	
...
 It’s	
  `me	
  to	
  share!
CAN	
  WE	
  GET	
  IT	
  EVEN	
  SMARTER?
What	
  Emmanuel	
  wants...
…	
  the	
  most	
  likely	
  ones.	
  
Recap
Call	
  CompleJon
Code	
  Snippet	
  CompleJon
Overrides	
  CompleJon
Chain	
  CompleJon
How	
  it	
  works
90
Code	
  Recommenders	
  
Knowledge	
  Base
❷
Mine	
  data,
extract	
  code	
  pamerns,
create	
  rec...
“And	
  what	
  about	
  my	
  APIs?”
Demo:	
  Mining	
  the	
  JavaFX	
  APIs
Get	
  the	
  Developer	
  Preview
www.
.com/download
How	
  about	
  IntelliJ	
  and	
  Netbeans?	
  Tweet!
Netbeans:
@geertjanw	
  Code	
  Recommenders	
  is	
  very	
  cool!...
NULL	
  ANNOTATIONS	
  IN	
  ECLIPSE	
  
Gerng	
  rid	
  of	
  NullPointerExcepJons...
PrevenJng	
  NullPointerExcepJons
Enabling	
  Null	
  Analysis
Overriding	
  Null	
  Analysis	
  AnnotaJons
GENERAL	
  TOOLS	
  FOR	
  ECLIPSE	
  4
PIMP	
  YOUR	
  ECLIPSE
Eclipse	
  4	
  UI	
  was	
  torn	
  into	
  shreds.	
  Is	
  there	
  any	
  easy	
  way	
  to	
 ...
Eclipse	
  4	
  Chrome	
  Theme	
  
Eclipse	
  4	
  Chrome	
  Theme
Get	
  it	
  from	
  Eclipse	
  Marketplace
Eclipse	
  Color	
  Theme
Eclipse	
  Color	
  Theme
Eclipse	
  Color	
  Theme
SHARING	
  PREFERENCES	
  IN	
  ENTERPRISES
Same	
  serngs	
  everywhere...
Any	
  default	
  value	
  can	
  be	
  overridden	
  by	
  a	
  properJes	
  file	
  specified	
  
on	
  startup	
  as	
  f...
Workspace	
  Mechanic
Workspace	
  Mechanic	
  -­‐	
  DetecJng	
  Issues
Workspace	
  Mechanic	
  -­‐	
  Fix	
  it!
Configuring	
  Workspace	
  Mechanic
Configuring	
  Workspace	
  Mechanic
Configuring	
  Workspace	
  Mechanic
ECLIPSE	
  AND	
  (REMOTE)	
  SHELLS
Easy	
  Shell
EasyShell
Remote	
  Systems	
  Explorer
Virtual	
  Machine	
  Serngs
Take	
  with	
  a	
  grain	
  of	
  salt!	
  
Every	
  VM	
  and	
  Eclipse	
  installaXon	
 ...
BUILD	
  YOUR	
  OWN	
  ECLIPSE	
  -­‐	
  ECLIPSE	
  CBI
All	
  you	
  need
#> git clone -b master --recursive git://git.eclipse.org/
gitroot/platform/eclipse.platform.releng.aggr...
supported	
  by
The	
  Knowledge	
  Transfer	
  Company
THANKS
DWX 2013 Nuremberg
DWX 2013 Nuremberg
DWX 2013 Nuremberg
DWX 2013 Nuremberg
DWX 2013 Nuremberg
Upcoming SlideShare
Loading in...5
×

DWX 2013 Nuremberg

566

Published on

Eclipse Tips, Tricks and Tools. Tools every developer should know.

Published in: Technology
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
566
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
13
Comments
0
Likes
2
Embeds 0
No embeds

No notes for slide

Transcript of "DWX 2013 Nuremberg"

  1. 1. Tips,  Tricks  &  Tools every  Eclipse  User  should  know
  2. 2. • Project  Lead  of  Eclipse  Code  Recommenders • Eclipse  Commi7er  since  2010 • Plug-­‐in  Developer  for  10  years  (Eclipse  2.1) • Eclipse  4  and  OSGI  Trainer • Co-­‐Lead  of  Java  User  Group  Darmstadt • Speaker  at  JUGs,  EclipseCon,  JavaOne... • PhD  in  Computer  Science • CEO  of  Codetrails • Passion  to  improve  developers  day-­‐to-­‐day  work   with  intelligent  and  prac8cal  tools  -­‐  mostly  using   Data  Mining  on  Big  (So?ware  Engineering)  Data.                      @MarcelBruch                        +MarcelBruch About  me
  3. 3. supported  by About  us The  Knowledge  Transfer  Company
  4. 4. Disclaimer  ;-­‐) Not  all  tools  I’m  talking  about   today  are  free  or  open  source. I  assume  all  a7endees  are   familiar  with  (i)  refactorings  in   Eclipse,  (ii)  generaXng   ge7ers/se7er,  hashCode,   equals++  with  Eclipse,  and  (iii)   you  daily  use  keyboard   shortcuts. No  refactorings  and  (almost)  no  shortcuts  today!
  5. 5. If  you  don’t  know  your  keyboard  shortcuts...
  6. 6. No  Mouse!  #dcr13
  7. 7. ⌘3
  8. 8. Quick  Access  –  ⌘3  
  9. 9. WHAT’S  NEW  IN  ECLIPSE  KEPLER?
  10. 10. Eclipse  Kepler  by  Numbers (c)  Holger  Voormann  <eclipse@voormann.de>
  11. 11. New  and  Noteworthy • Pla[orm  performance  improvements • Pla[orm  builds  with  Eclipse  CBI • IniXal  GTK+  3  support • Eclipse  Orion  3.0 • Eclipse  Jubula  support  for  tesXng  mobile  devices • Install  remedia.on • EGit  3.0 • Mylyn  Reviews • JDT  (usability)  improvements
  12. 12. REMEDIATION  SUPPORT  IN  ECLIPSE
  13. 13. Installing  new  features  can  be  painful...
  14. 14. Not  (that  much)  with  Eclipse’s  new   Install  RemediaJon  Feature!
  15. 15. UPDATING  FROM  ECLIPSE  3.X  -­‐-­‐>  4.X OMG,  I  don’t  want  to  reinstall  all  my  plugins  again...
  16. 16. Install  soQware  items  from  exisJng  installaJon...
  17. 17. Select  which  features  to  import...
  18. 18. Want  to  prepare  a  company  wide  install  file?
  19. 19. Export  soQware  items  w/  update  sites
  20. 20. EGIT/JGIT  3.0  
  21. 21. Git  in  Eclipse  -­‐  EGit  3.0
  22. 22. Rename  DetecJon
  23. 23. Reset  Repository  to  Expression
  24. 24. Clean  Repository
  25. 25. Commit  and  Push  (at  once)
  26. 26. GERRIT  &  MYLYN  REVIEWS Four  eyes  can  see  more  than  two...
  27. 27. Gerrit  at  Eclipse
  28. 28. Reviewing  Changes  with  Gerrit
  29. 29. Gerrit  Workflow Gerrit Hudson Git 3.  Build2.  Pull 4.  Verified 6.  Push 7.  Pull 1.  Push 5.  Approve
  30. 30. HOW  IS  MYLYN  REVIEWS  GOING  TO  CHANGE  THIS?
  31. 31. 1.  Push  and  Pull  to  Gerrit  from  your  IDE   Feature  in  EGit
  32. 32. 2.  Review  changes  in  your  IDE
  33. 33. 3.  Submit  the  approved  change
  34. 34. 4.  Get  noJficaJons  about  new  change-­‐sets
  35. 35. Mylyn  Builds
  36. 36. WHEN  EDITING  SOURCE  CODE The  simple  basics...
  37. 37. Smart  Semicolons  &  Braces
  38. 38. Matching  Enclosing  Brackets
  39. 39. “Faster”  IntelliJ-­‐like  Code  CompleJon .abcdefghijklmnopqrstuvwxyz
  40. 40. Favorites  for  import static
  41. 41. Type  Filters
  42. 42. WHEN  DEBUGGING  IN  ECLIPSE The  hidden  and  rarely  used  jewels...
  43. 43. Step  Filtering
  44. 44. Debug  Details  Formamer
  45. 45. Debug  Logical  Structure
  46. 46. Extending  Logical  Structures
  47. 47. Extending  Logical  Structures
  48. 48. Heap  Walking
  49. 49. Eclipse  Memory  Analyzer  (MAT)
  50. 50. Drop  to  Frame
  51. 51. JRebel  Feature  Comparison  Matrix
  52. 52. Supported  Frameworks
  53. 53. Get  it  from  Eclipse  Marketplace
  54. 54. Test  Coverage  with  EclEmma
  55. 55. Test  Coverage  with  EclEmma
  56. 56. CODE  COMPLETIONS  IN  ECLIPSE Smarter  than  I  expected...
  57. 57. Into  Code-­‐Comple`on  Wonderland
  58. 58. ⌘1
  59. 59. Quick  Fix  –  ⌘1
  60. 60. ⌘2
  61. 61. Quick  Assist  –  ⌘2
  62. 62. ⌃  Space
  63. 63. Content  Assist  –  ⌃Space
  64. 64. ⌃  .
  65. 65. SUBWORDS  COMPLETION “BecauseCamelCaseMatching****s!”
  66. 66. Subwords  CompleJon
  67. 67. Install  Subwords  from  Eclipse  Marketplace
  68. 68. So  many  wonderful  engines?
  69. 69. "[In  Eclipse]  sort  by  relevance  is  synonymous  to  alphabe`cal.   In  other  words  it  sucks...  but  in  a  predictably  alphabe`cal   way."
  70. 70. @Override protected Control createDialogArea(final Composite parent) { Composite container = (Composite) super.createDialogArea(parent); swtTextWidget = new Text(container, SWT.BORDER); swtTextWidget.| return container; } What  Emmanuel  gets What  does  Emmanuel  get  when  triggering  code  comple`on  here?
  71. 71. All  164  proposals  sorted  by  “Relevance”
  72. 72. What  Emanuel  wants...
  73. 73. Learning  Constructor  CompleJons
  74. 74.  Codetrails  Hippie  CompleJon
  75. 75. And  win  10  Raspberry  PIs!
  76. 76. How  about  IntelliJ  and  Netbeans?  Tweet! Netbeans: @geertjanw  Crowdsourced  Hippie  Comple`on  is  very   cool!  When  can  I  have  it  for  Netbeans? IntelliJ: @andrey_cheptsov  Crowdsourced  Hippie  Comple`on   is  very  cool!  When  can  I  have  it  in  IntelliJ?
  77. 77.  It’s  `me  to  share!
  78. 78. CAN  WE  GET  IT  EVEN  SMARTER?
  79. 79. What  Emmanuel  wants... …  the  most  likely  ones.  
  80. 80. Recap
  81. 81. Call  CompleJon
  82. 82. Code  Snippet  CompleJon
  83. 83. Overrides  CompleJon
  84. 84. Chain  CompleJon
  85. 85. How  it  works 90 Code  Recommenders   Knowledge  Base ❷ Mine  data, extract  code  pamerns, create  recommendaJon  models ❸ deliver  mined knowledge  to  Eclipse  users ❶   Analyze  source  code
  86. 86. “And  what  about  my  APIs?”
  87. 87. Demo:  Mining  the  JavaFX  APIs
  88. 88. Get  the  Developer  Preview www. .com/download
  89. 89. How  about  IntelliJ  and  Netbeans?  Tweet! Netbeans: @geertjanw  Code  Recommenders  is  very  cool!  When   can  I  have  it  for  Netbeans? IntelliJ: @andrey_cheptsov  Code  Recommenders  is  very  cool!   When  can  I  have  it  in  IntelliJ?
  90. 90. NULL  ANNOTATIONS  IN  ECLIPSE   Gerng  rid  of  NullPointerExcepJons...
  91. 91. PrevenJng  NullPointerExcepJons
  92. 92. Enabling  Null  Analysis
  93. 93. Overriding  Null  Analysis  AnnotaJons
  94. 94. GENERAL  TOOLS  FOR  ECLIPSE  4
  95. 95. PIMP  YOUR  ECLIPSE Eclipse  4  UI  was  torn  into  shreds.  Is  there  any  easy  way  to  get  a  nice  UI?
  96. 96. Eclipse  4  Chrome  Theme  
  97. 97. Eclipse  4  Chrome  Theme
  98. 98. Get  it  from  Eclipse  Marketplace
  99. 99. Eclipse  Color  Theme
  100. 100. Eclipse  Color  Theme
  101. 101. Eclipse  Color  Theme
  102. 102. SHARING  PREFERENCES  IN  ENTERPRISES Same  serngs  everywhere...
  103. 103. Any  default  value  can  be  overridden  by  a  properJes  file  specified   on  startup  as  follows: Preferences -- launch -- eclipse.exe -plugincustomization /path/to/plugin_customization.ini -- plugin_customization.ini -- org.eclipse.jdt.ui/content_assist_autoactivation_triggers_java=. org.eclipse.jdt.ui/content_assist_autoactivation_delay=5
  104. 104. Workspace  Mechanic
  105. 105. Workspace  Mechanic  -­‐  DetecJng  Issues
  106. 106. Workspace  Mechanic  -­‐  Fix  it!
  107. 107. Configuring  Workspace  Mechanic
  108. 108. Configuring  Workspace  Mechanic
  109. 109. Configuring  Workspace  Mechanic
  110. 110. ECLIPSE  AND  (REMOTE)  SHELLS
  111. 111. Easy  Shell
  112. 112. EasyShell
  113. 113. Remote  Systems  Explorer
  114. 114. Virtual  Machine  Serngs Take  with  a  grain  of  salt!   Every  VM  and  Eclipse  installaXon  is  different. -­‐Xincgc -­‐Xss1m -­‐Duser.name=FirstName  LastName -­‐Dfile.encoding=UTF-­‐8 -­‐Dosgi.requiredJavaVersion=1.7 -­‐Declipse.p2.unsignedPolicy=allow -­‐Declipse.p2.MD5Check=false -­‐Xms512m -­‐Xmx2g -­‐XX:NewSize=16m -­‐XX:PermSize=120m -­‐XX:MaxPermSize=300m -­‐XX:MaxPermHeapExpansion=20m -­‐XX:+UseConcMarkSweepGC -­‐XX:CMSInitiatingOccupancyFraction=70 -­‐XX:+UseCMSInitiatingOccupancyOnly -­‐XX:+UseParNewGC -­‐XX:+CMSConcurrentMTEnabled -­‐XX:ConcGCThreads=2 -­‐XX:ParallelGCThreads=2 -­‐XX:+CMSIncrementalPacing -­‐XX:CMSIncrementalDutyCycleMin=0 -­‐XX:CMSIncrementalDutyCycle=5 -­‐XX:GCTimeRatio=49 -­‐XX:MaxGCPauseMillis=20 -­‐XX:GCPauseIntervalMillis=1000 -­‐XX:+UseCMSCompactAtFullCollection -­‐XX:+CMSClassUnloadingEnabled -­‐XX:+DoEscapeAnalysis -­‐XX:+UseCompressedOops -­‐XX:+AggressiveOpts
  115. 115. BUILD  YOUR  OWN  ECLIPSE  -­‐  ECLIPSE  CBI
  116. 116. All  you  need #> git clone -b master --recursive git://git.eclipse.org/ gitroot/platform/eclipse.platform.releng.aggregator.git #> mvn clean verify
  117. 117. supported  by The  Knowledge  Transfer  Company
  118. 118. THANKS
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×