Is it possible to use PhpStorm inspection results for continuous integration services?
Hello all,
it would be nice to use PhpStorm inspection results inside of a continuous integration system. Is there any possiblity to integrate it automagically via command line and export results in XML (e. g. for Hudson/Jenkins)?
Greetz and thanks
Thomas
Please sign in to leave a comment.
Currently you can export them manually:
Not sure about command line.
Sure. This should apply to all our IDEs http://www.jetbrains.com/idea/webhelp/running-inspections-offline.html
Thanks :D Great!
In current release 2.0 (linux) there is no inspect.sh or inspect.bat. Is this correct or should I create an issue in the tracker?
BTW: Thanks for release!
Well its contents for idea is is just
#!/bin/sh
./idea.sh inspect $*
Hm, i'm trying to get messages out of my PhpStorm (Release 2.0), but it fails with an error. Anything wrong with my Java installation or is this a bug?
Java HotSpot(TM) 64-Bit Server VM (build 19.1-b02, mixed mode)
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.ide.plugins.PluginManager$2.run(PluginManager.java:169)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.ExceptionInInitializerError
at com.sun.java.swing.plaf.gtk.GTKLookAndFeel.getGTKStyleFactory(GTKLookAndFeel.java:1543)
at com.sun.java.swing.plaf.gtk.GTKLookAndFeel.loadStyles(GTKLookAndFeel.java:1507)
at com.sun.java.swing.plaf.gtk.GTKLookAndFeel.initialize(GTKLookAndFeel.java:1394)
at javax.swing.UIManager.setLookAndFeel(UIManager.java:513)
at javax.swing.UIManager.setLookAndFeel(UIManager.java:558)
at com.intellij.ide.a.d.x.a(x.java:73)
at com.intellij.idea.MainImpl._main(MainImpl.java:134)
at com.intellij.idea.MainImpl.start(MainImpl.java:69)
... 6 more
Caused by: java.awt.HeadlessException
at sun.java2d.HeadlessGraphicsEnvironment.getDefaultScreenDevice(HeadlessGraphicsEnvironment.java:64)
at com.sun.java.swing.plaf.gtk.PangoFonts.<clinit>(PangoFonts.java:43)
... 14 more
[ 108] ERROR - llij.ide.plugins.PluginManager - Error while accessing com.intellij.idea.MainImpl.start with arguments: [inspect]
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.ide.plugins.PluginManager$2.run(PluginManager.java:169)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.ExceptionInInitializerError
at com.sun.java.swing.plaf.gtk.GTKLookAndFeel.getGTKStyleFactory(GTKLookAndFeel.java:1543)
at com.sun.java.swing.plaf.gtk.GTKLookAndFeel.loadStyles(GTKLookAndFeel.java:1507)
at com.sun.java.swing.plaf.gtk.GTKLookAndFeel.initialize(GTKLookAndFeel.java:1394)
at javax.swing.UIManager.setLookAndFeel(UIManager.java:513)
at javax.swing.UIManager.setLookAndFeel(UIManager.java:558)
at com.intellij.ide.a.d.x.a(x.java:73)
at com.intellij.idea.MainImpl._main(MainImpl.java:134)
at com.intellij.idea.MainImpl.start(MainImpl.java:69)
Caused by: java.awt.HeadlessException
at sun.java2d.HeadlessGraphicsEnvironment.getDefaultScreenDevice(HeadlessGraphicsEnvironment.java:64)
at com.sun.java.swing.plaf.gtk.PangoFonts.<clinit>(PangoFonts.java:43)
... 14 more
[ 108] ERROR - llij.ide.plugins.PluginManager - Error while accessing com.intellij.idea.MainImpl.start with arguments: [inspect]
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.ide.plugins.PluginManager$2.run(PluginManager.java:169)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.ExceptionInInitializerError
at com.sun.java.swing.plaf.gtk.GTKLookAndFeel.getGTKStyleFactory(GTKLookAndFeel.java:1543)
at com.sun.java.swing.plaf.gtk.GTKLookAndFeel.loadStyles(GTKLookAndFeel.java:1507)
at com.sun.java.swing.plaf.gtk.GTKLookAndFeel.initialize(GTKLookAndFeel.java:1394)
at javax.swing.UIManager.setLookAndFeel(UIManager.java:513)
at javax.swing.UIManager.setLookAndFeel(UIManager.java:558)
at com.intellij.ide.a.d.x.a(x.java:73)
at com.intellij.idea.MainImpl._main(MainImpl.java:134)
at com.intellij.idea.MainImpl.start(MainImpl.java:69)
... 6 more
Caused by: java.awt.HeadlessException
at sun.java2d.HeadlessGraphicsEnvironment.getDefaultScreenDevice(HeadlessGraphicsEnvironment.java:64)
at com.sun.java.swing.plaf.gtk.PangoFonts.<clinit>(PangoFonts.java:43)
... 14 more
[ 111] ERROR - llij.ide.plugins.PluginManager - JDK: 1.6.0_24
[ 111] ERROR - llij.ide.plugins.PluginManager - VM: Java HotSpot(TM) 64-Bit Server VM
[ 111] ERROR - llij.ide.plugins.PluginManager - Vendor: Sun Microsystems Inc.
[ 111] ERROR - llij.ide.plugins.PluginManager - OS: Linux
[ 111] ERROR - llij.ide.plugins.PluginManager - Original exception:
Tried different parameters behind "inspect" (project source directory, file name, ...) but everytime i get these error messages.
Please attach here complete command line.
Seems that java.awt.headless was not set while you run headless application. IDEA sets this property on inspections start - so the problem is somewhere in the command line
Thank you
My command line is now (added -v2):
Where /home/tw/webs/abc is the main folder of my PhpStorm project. I also tried the following:
Thomas, please try the following
.iml file contains information about IDEA's module but there should be a path to the project (.idea should be enough)
output - should be a directory.
Thank you
Created a new, clean directory under /home/tw/out and tried your option string, but still same result :-/
Please try path to your project /home/tw/webs/abc/.idea
Do not add tailing slash please. Do you see the same exceptions? Thank you
Yes, same exceptions with or without trailing slash.
Any chance to get this working for me?
sorry but you reallys need to file an issue to tracker - or your problem will be lost.