Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
62 lines (49 sloc) 1.36 KB
def releaseVersion = "5.2.4-SNAPSHOT"
def targetDirBase = './release/' + releaseVersion + '/'
def targetDir = targetDirBase + "/websoccer"
def targetUpdateDir = targetDirBase + '/update/websoccer'
task release << {
println 'Starting release. Make sure you disabled DEBUG mode in software.'
}
release << {
versionfile = new File('./websoccer/admin/config/version.txt')
versionfile.text = releaseVersion
println 'Updated version file'
}
release << {
copy {
from './websoccer'
into targetDir
exclude '.gradle'
exclude '.settings'
exclude '.buildpath'
exclude '.project'
exclude 'dberrorlog.txt'
exclude 'admin/dberrorlog.txt'
exclude 'build.gradle'
exclude 'cache/*'
exclude 'update'
exclude 'uploads/club/*'
exclude 'uploads/cup/*'
exclude 'uploads/player/*'
exclude 'uploads/sponsor/*'
exclude 'uploads/stadiumbuilder/*'
exclude 'uploads/stadium/*'
exclude 'uploads/stadiumbuilding/*'
exclude 'uploads/users/*'
exclude 'generated/*'
}
println 'Copied files'
}
release << {
copy {
from './websoccer'
include 'classes/**'
include 'admin/config/version.txt'
include 'update/**'
into targetUpdateDir
}
println 'Copied files for update'
}
task build(dependsOn: release) {
}