Skip to content
Snippets Groups Projects
Select Git revision
  • bf825890a143531cbea3d23935b93eb648f5fe8d
  • develop default protected
  • master protected
  • 1.2.1
  • 1.2.0
  • 1.1.0
  • 1.0.5
  • 1.0.4
  • 1.0.3
  • 1.0.2
  • 1.0.0
11 results

build.gradle

Blame
  • Code owners
    Assign users and groups as approvers for specific file changes. Learn more.
    tycho_build.gradle 25.47 KiB
    import org.apache.tools.ant.taskdefs.condition.Os
    /*
    	Build Script can be executed via 'gradle install'
    	Build Script Dependencies can be downloaded via 'gradle collectDepenencies'
    	Executing the Build Script and download Dependencies can be executed via 'gradle completeInstall'
     	For a complete classPath Refresh please execute 'gradle deleteFromClassPath setClassPath'
    	Pom Generation can be executed via gradle deploy
    
    	If you have a product definition please add a buildProduct = true to your main build.gradle script
    
    */
    
    
    apply plugin: 'base'
    
    import groovy.io.FileType
    project.ext.tychoVersion = "1.0.0"
    
    try{
    	excludeFromTychoBuild = excludeFromTychoBuild
    }catch(MissingPropertyException e){
    	project.ext.excludeFromTychoBuild = []
    }
    
    try{
    	excludeFromClassPath = excludeFromClassPath
    }catch(MissingPropertyException e){
    	project.ext.excludeFromClassPath = []
    }
    
    
    try{
    	workspacePath = workspacePath
    }catch(MissingPropertyException e){
    	project.ext.workspacePath = ""
    }
    
    
    try{
    	dependencyFolder = dependencyFolder
    }catch(MissingPropertyException e){
    	project.ext.dependencyFolder = "lib/dependencies/"			// Folder in each subproject where
    }
    
    try{
    	groupID = groupID
    }catch(MissingPropertyException e){
    
    	// workspace nach releng durchsuchen
    	def folderNames = []
    	def folders = []
    	println "folders:"
    	new File(workspacePath+".").listFiles().each{ dir ->
    	    if( dir.isDirectory() ) folders <<  dir.getName()
    	}
    
    	folders.each(){ it ->
    		it = (String)it.replaceFirst(/\.\//, "")
    		if( !( ( it ==~ /\..+/ ) || (it ==~ /.*.repository/) || (it ==~ /.*.parent/) ) ) folderNames << it			// subProjects eventuell unnötig settings.gradle datei stattdessen benutzen
    	}
    
    
    	project.ext.groupID = "group"
    	for( int  i = 0; i < folderNames.size(); i++ ){
    
    		if( folderNames[i] ==~ /.*\.[rR]eleng/ ){
    			groupID = folderNames[i]
    			groupID = groupID.replace( ".releng", "")
    			groupID = groupID.replace( ".Releng", "")
    		}