Logger.debug("composer.json already exists in the location");
return;
}
ComposerPackage composerPackage = firstPage.getPackage();
VersionedPackage phpVersion = new VersionedPackage();
phpVersion.setName("php");
phpVersion.setVersion(">=" + firstPage.getPHPVersionValue().getAlias().replace("php", ""));
composerPackage.getRequire().add(phpVersion);
ByteArrayInputStream bis = new ByteArrayInputStream(composerPackage.toJson().getBytes());
file.create(bis, true, monitor);
getProject().refreshLocal(0, monitor);