Revision: 4627 http://sourceforge.net/p/vexi/code/4627 Author: mkpg2 Date: 2013-12-21 21:55:28 +0000 (Sat, 21 Dec 2013) Log Message: ----------- Changes. - make core/vexi properties not mandatory - pretty print json (easier to edit)
Modified Paths: -------------- trunk/org.vexi-build.deployment/meta/module.xml trunk/org.vexi-build.deployment/src/main/java/org/vexi/build/deployment/VexiDeploymentAssembler.java trunk/org.vexi-build.shared/meta/module.revisions trunk/org.vexi-build.shared/meta/module.xml Modified: trunk/org.vexi-build.deployment/meta/module.xml =================================================================== --- trunk/org.vexi-build.deployment/meta/module.xml 2013-12-21 11:26:26 UTC (rev 4626) +++ trunk/org.vexi-build.deployment/meta/module.xml 2013-12-21 21:55:28 UTC (rev 4627) @@ -7,5 +7,7 @@ <dependency source="local" name="tools.certify" /> <dependency source="ebuild" name="api.plugin" tag="0.8.0" /> <dependency source="ebuild-plugins" name="lib.util" /> + <dependency source="eapi" name="lib.udon" /> + </dependencies> </ebuild-module> Modified: trunk/org.vexi-build.deployment/src/main/java/org/vexi/build/deployment/VexiDeploymentAssembler.java =================================================================== --- trunk/org.vexi-build.deployment/src/main/java/org/vexi/build/deployment/VexiDeploymentAssembler.java 2013-12-21 11:26:26 UTC (rev 4626) +++ trunk/org.vexi-build.deployment/src/main/java/org/vexi/build/deployment/VexiDeploymentAssembler.java 2013-12-21 21:55:28 UTC (rev 4627) @@ -5,6 +5,8 @@ import org.vexi.util.IOUtil; +import udon.UDON; + import ebuild.api.*; import ebuild.api.log.ILogger; import ebuild.api.plugin.*; @@ -27,7 +29,7 @@ final File output = arg.getOutputDirectory(); final String templateName = props.getString("launcher-page", "index.html"); final File launcher = inputs.expectInput("launcher").expectLoneArtifact(); - final File core = inputs.expectInput("core").expectLoneArtifact(); + final File core = inputs.getInput("core")==null?null:inputs.getInput("core").expectLoneArtifact(); try { new Callable<Object, Exception>() { private String template; @@ -66,6 +68,7 @@ } private String generateParams(Collection<String> vexis) throws Exception{ + if(core==null) throw new BuildPluginException("Cannot generate page, 'core' input not set"); String ROOT = props.expectString("root"); StringBuilder sb = new StringBuilder(); sb.append( @@ -104,7 +107,8 @@ output.mkdirs(); copyToDir("launcher", launcher); - copyToDir("core", core); + if(core!=null) + copyToDir("core", core); ////////////////////////////////////////////////////////// // PROCESS launcher page input (template and static files) @@ -129,7 +133,7 @@ // - a single list of vexis // - multiple named applications Map<String,IInput> vexisInput = justVexis(); - if(vexisInput.size()==0) throw new BuildPluginException("No 'vexis*' inputs provided"); + //if(vexisInput.size()==0) throw new BuildPluginException("No 'vexis*' inputs provided"); Set<File> vexiFilesAll = new HashSet(); Map<String,Collection<String>> vexisMap = new HashMap(); @@ -151,11 +155,12 @@ Map m = new LinkedHashMap(); m.put("applet-jar",launcher.getName()); m.put("applet-class",props.expectString("applet-class")); - m.put("core-signed",core.getName()); + if(core!=null) + m.put("core-signed",core.getName()); m.putAll(vexisMap); File file = new File(output, launcherJson); - JSONUtil.writeObject(file, m); + IOUtil.stringToFile(UDON.prettyPrint(m), file); } return null; } Modified: trunk/org.vexi-build.shared/meta/module.revisions =================================================================== --- trunk/org.vexi-build.shared/meta/module.revisions 2013-12-21 11:26:26 UTC (rev 4626) +++ trunk/org.vexi-build.shared/meta/module.revisions 2013-12-21 21:55:28 UTC (rev 4627) @@ -1 +1 @@ -{"https:\/\/ebuild-project.org\/svn\/ebuild\/plugins":"152"} \ No newline at end of file +{"https:\/\/ebuild-project.org\/svn\/ebuild\/plugins":"152","https:\/\/emanate-project.org\/svn\/eapi":"158"} \ No newline at end of file Modified: trunk/org.vexi-build.shared/meta/module.xml =================================================================== --- trunk/org.vexi-build.shared/meta/module.xml 2013-12-21 11:26:26 UTC (rev 4626) +++ trunk/org.vexi-build.shared/meta/module.xml 2013-12-21 21:55:28 UTC (rev 4627) @@ -4,6 +4,9 @@ name="ebuild-plugins" branch="0.8" org="ebuild" type="svn" url="https://ebuild-project.org/svn/ebuild/plugins/"/> - </repositories> + <repository + name="eapi" + org="eapi" type="svn" url="https://emanate-project.org/svn/eapi/"/> + </repositories> <dependencies/> </ebuild-module> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Rapidly troubleshoot problems before they affect your business. Most IT organizations don't have a clear picture of how application performance affects their revenue. With AppDynamics, you get 100% visibility into your Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro! http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk _______________________________________________ Vexi-svn mailing list Vexi-svn@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/vexi-svn