Source:
<code>public void execute() throws MojoExecutionException { if (contextPath == null) { String contextPathProperty = System.getProperty( NinjaJetty.COMMAND_LINE_PARAMETER_NINJA_CONTEXT); contextPath = contextPathProperty; } devPort = System.getProperty(NinjaJetty.COMMAND_LINE_PARAMETER_NINJA_PORT); <START> if(devPort == null){ <END> devPort = "8080"; } getLog().debug( "Directory for classes is (used to start local jetty and watch for changes: " + buildOutputDirectory); getLog().info("------------------------------------------------------------------------"); if (contextPath != null) { getLog().info("Launching Ninja SuperDevMode with '" + contextPath + "' context path."); } else { getLog().info("Launching Ninja SuperDevMode on root context"); } getLog().info("Ninja Will launch on the following port: " + devPort); getLog().info("------------------------------------------------------------------------"); initMojoFromUserSubmittedParameters(); List<String> classpathItems = Lists.newArrayList(); alertAndStopExecutionIfDirectoryWithCompiledClassesOfThisProjectDoesNotExist( buildOutputDirectory); classpathItems.add(buildOutputDirectory); for (org.apache.maven.artifact.Artifact artifact : mavenProject.getArtifacts()) { classpathItems.add(artifact.getFile().toString()); } List<Artifact> allArtifactsFromNinjaStandaloneInPlugin = getAllArtifactsComingFromNinjaStandalone(pluginArtifacts); for (Artifact artifact : allArtifactsFromNinjaStandaloneInPlugin) { if (!classpathItems.contains(artifact.getFile().toString())) { classpathItems.add(artifact.getFile().toString()); } } Path directoryToWatchRecursivelyForChanges = FileSystems.getDefault().getPath( buildOutputDirectory); try { WatchAndRestartMachine nWatchAndTerminate = new WatchAndRestartMachine( NinjaMavenPluginConstants.NINJA_JETTY_CLASSNAME, directoryToWatchRecursivelyForChanges, classpathItems, excludesAsList, contextPath, devPort); nWatchAndTerminate.startWatching(); } catch (IOException e) { getLog().error(e); } }</code><technical_language>if (devPort == null) { (with spaces). convention. Sounds strange - tiny codebase nice in long run :)</technical_language>

Target:
public void execute() throws MojoExecutionException { if (contextPath == null) { String contextPathProperty = System.getProperty( NinjaJetty.COMMAND_LINE_PARAMETER_NINJA_CONTEXT); contextPath = contextPathProperty; } if (port == null) { String portProperty = System.getProperty( NinjaJetty.COMMAND_LINE_PARAMETER_NINJA_PORT, "8080"); port = portProperty; } getLog().debug( "Directory for classes is (used to start local jetty and watch for changes: " + buildOutputDirectory); getLog().info("------------------------------------------------------------------------"); if (contextPath != null) { getLog().info("Launching Ninja SuperDevMode with '" + contextPath + "' context path."); } else { getLog().info("Launching Ninja SuperDevMode on root context"); } getLog().info("Ninja Will launch on the following port: " + port); getLog().info("------------------------------------------------------------------------"); initMojoFromUserSubmittedParameters(); List<String> classpathItems = Lists.newArrayList(); alertAndStopExecutionIfDirectoryWithCompiledClassesOfThisProjectDoesNotExist( buildOutputDirectory); classpathItems.add(buildOutputDirectory); for (org.apache.maven.artifact.Artifact artifact : mavenProject.getArtifacts()) { classpathItems.add(artifact.getFile().toString()); } List<Artifact> allArtifactsFromNinjaStandaloneInPlugin = getAllArtifactsComingFromNinjaStandalone(pluginArtifacts); for (Artifact artifact : allArtifactsFromNinjaStandaloneInPlugin) { if (!classpathItems.contains(artifact.getFile().toString())) { classpathItems.add(artifact.getFile().toString()); } } Path directoryToWatchRecursivelyForChanges = FileSystems.getDefault().getPath( buildOutputDirectory); try { WatchAndRestartMachine nWatchAndTerminate = new WatchAndRestartMachine( NinjaMavenPluginConstants.NINJA_JETTY_CLASSNAME, directoryToWatchRecursivelyForChanges, classpathItems, excludesAsList, contextPath, port); nWatchAndTerminate.startWatching(); } catch (IOException e) { getLog().error(e); } }