|  | @@ -21,6 +21,7 @@ package org.elasticsearch.gradle.plugin
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  import org.elasticsearch.gradle.test.RestIntegTestTask
 | 
	
		
			
				|  |  |  import org.elasticsearch.gradle.test.RestTestPlugin
 | 
	
		
			
				|  |  | +import org.elasticsearch.gradle.test.RunTask
 | 
	
		
			
				|  |  |  import org.elasticsearch.gradle.test.StandaloneRestTestPlugin
 | 
	
		
			
				|  |  |  import org.gradle.api.Plugin
 | 
	
		
			
				|  |  |  import org.gradle.api.Project
 | 
	
	
		
			
				|  | @@ -42,6 +43,10 @@ class MetaPluginBuildPlugin implements Plugin<Project> {
 | 
	
		
			
				|  |  |              distribution = 'zip'
 | 
	
		
			
				|  |  |              setupCommand('installMetaPlugin', 'bin/elasticsearch-plugin', 'install', 'file:' + project.bundlePlugin.archivePath)
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +        RunTask run = project.tasks.create('run', RunTask)
 | 
	
		
			
				|  |  | +        run.dependsOn(project.bundlePlugin)
 | 
	
		
			
				|  |  | +        run.clusterConfig.plugin(project.path)
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |      private static void createBundleTask(Project project) {
 | 
	
	
		
			
				|  | @@ -63,6 +68,10 @@ class MetaPluginBuildPlugin implements Plugin<Project> {
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |          project.assemble.dependsOn(bundle)
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | +        // also make the zip available as a configuration (used when depending on this project)
 | 
	
		
			
				|  |  | +        project.configurations.create('zip')
 | 
	
		
			
				|  |  | +        project.artifacts.add('zip', bundle)
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  |          // a super hacky way to inject code to run at the end of each of the bundled plugin's configuration
 | 
	
		
			
				|  |  |          // to add itself back to this meta plugin zip
 | 
	
		
			
				|  |  |          project.afterEvaluate {
 |