I am currently working on Guidewire Studio built on top of IntelliJ. I have installed the codenarc plugin into the studio but it seems like the rules of codenarc is not running for my codes. After analyzing the codes it does not give me any violation which i know, is there. Can someone please tell me what am i missing here.
-
Do you get any warning/error messages in idea.log ("Help | Show Log in...")? – y.bedrov Jan 17 '18 at 16:02
-
No i do not. Neither while starting the server or while inspecting the codes @y.bedrov – pradyumn Jan 22 '18 at 10:31
-
@pradyumn I've updated my answer below, care to provide any feedback? – hakamairi Jan 15 '19 at 11:56
2 Answers
You probably can't, but there's a workaround.
Guidewire provides their customers with GosuCodeNarc which is basically CodeNarc extended with several gosu rules' implementations, possibly some glue code as well. If you are missing any rules they provide documentation on creating any new ones.
This isn't shipped as a plugin, but rather a set of jars with instruction how to run them as gradle task (intended to be run on CD/CI).
EDIT
There is a way if you are on v9 or v10!
The inspection plugin to studio was intensively developed and is most likely meant to replace GosuCodeNarc entirely. Most importantly it provides all the inspections within the GW Studio.
The only requirement is to be on GW Studio v1.14 or higher and to turn inspections of choice within the inspections settings (use quick search to find this one).
Starting from v9.0.5 there's also a gradle task meant for command line use, so feel free to give it a try with
gwb inspect
More on it in
gwb help --task :inspect

- 4,464
- 4
- 30
- 53
-
I created a plugin on top of codenarc which has rules and logic for Gosu and is working fine on V9. But you were right about the problem. The rules which are embedded in the studio are less and i wanted to have more customs rules for code standard checking. Thnks :) – pradyumn Jan 24 '19 at 14:39