}
// Get the description using a partial compilation because it is much faster than compiling the class
// the class will be compiled lazyly
String resolveDescription = null;
CompilationUnit cu = new CompilationUnit(objectGroovyClassFactory.config);
cu.addSource(name, script);
try {
cu.compile(Phases.CONVERSION);
}
catch (CompilationFailedException e) {
throw new CommandException(ErrorKind.INTERNAL, "Could not compile command", e);
}
CompileUnit ast = cu.getAST();
if (ast.getClasses().size() > 0) {
ClassNode classNode= (ClassNode)ast.getClasses().get(0);
if (classNode != null) {
for (AnnotationNode annotation : classNode.getAnnotations()) {
if (annotation.getClassNode().getName().equals(Usage.class.getSimpleName())) {