if (!shell.promptBoolean(String.format("Dependency is managed [%s:%s:%s], reference the managed dependency?",
existingDep.getGroupId(), existingDep.getArtifactId(), existingDep.getVersion()), true))
{
if (Strings.isNullOrEmpty(gavCopy.getVersion()))
{
DependencyQuery query = DependencyQueryBuilder.create(gavCopy).setFilter(
new NonSnapshotDependencyFilter());
gavCopy = shell.promptChoiceTyped("Add which version?", deps.resolveAvailableVersions(query));
}
}
}