Skip to content

Instantly share code, notes, and snippets.

@BFergerson
Last active May 5, 2019 03:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BFergerson/03d00faa2b8587e92d856908f0859bce to your computer and use it in GitHub Desktop.
Save BFergerson/03d00faa2b8587e92d856908f0859bce to your computer and use it in GitHub Desktop.
SocraticAPI.administration().config(ConfigOption.cyclomatic_complexity, true).build().execute()
SocraticAPI.administration().init().build().execute() //installs Apache Skywalking and Babelfish via Docker
SocraticAPI.administration().addRemoteRepo()
.repoName("bfergerson/method-complexity")
.build().execute() //clones and scans https://github.com/bfergerson/method-complexity
println SocraticAPI.knowledge().question()
.question("what is the most complex method?")
.build().execute().answer
// Answer: ComplexMethods.mostComplexMethod()
// - https://github.com/BFergerson/method-complexity/blob/master/ComplexMethods.java#L26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment