Commit d95e3ff2 authored by Aneta Steimarova's avatar Aneta Steimarova

#754 Added changelog, copyright, tyblexia desktop and exec tablexia to deb package

parent 8cda08ef
Copyright (C) 2016 CZ.NIC, z.s.p.o. (http://www.nic.cz/)
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.
#!/bin/sh
java -jar /lib/tablexia/Tablexia.jar
[Desktop Entry]
Encoding=UTF-8
Name=Tablexia
Comment=Educational application
Exec=/bin/tablexia
Icon=/usr/share/tablexia/icon.png
Terminal=false
Type=Application
Categories=GNOME, Application
StartupNotify=true
......@@ -186,25 +186,64 @@ task debianDebugPackage (dependsOn: debugJar) {
def createDebPackage(String version) {
def tablexiaApp = tablexiaAppName + "-$version-" + tablexiaVersionName
def packageFolder = new File("/desktop/build/libs/$tablexiaApp");
packageFolder.mkdirs();
def packageFolder = new File("/desktop/build/libs/$tablexiaApp")
packageFolder.mkdirs()
new File("$packageFolder/usr/").mkdirs();
new File("$packageFolder/usr/bin").mkdirs();
new File("$packageFolder/usr/lib").mkdirs();
new File("$packageFolder/usr/share").mkdirs();
new File("$packageFolder/usr/lib/$tablexiaApp").mkdirs();
new File("$packageFolder/DEBIAN").mkdirs() // control
new File("$packageFolder/lib/tablexia").mkdirs() // .jar
new File("$packageFolder/bin").mkdirs() //exec tablexia
new File("$packageFolder/usr/share/applications").mkdirs() //tablexia.desktop
new File("$packageFolder/usr/share/doc/tablexia").mkdirs() // copyright, icon, changelog
//copy .jar file
copy {
from "../desktop/build/libs/$tablexiaApp" + ".jar"
into "../$packageFolder/usr/lib/$tablexiaApp/"
into "../$packageFolder/lib/tablexia/"
rename { String fileName ->
fileName.replace("$tablexiaApp" + ".jar", "Tablexia.jar")
}
}
//copy icon
copy {
from "../android/assets/icon/desktop_icon_$version" + "_32.png"
into "../$packageFolder/usr/share/doc/tablexia/"
rename { String fileName ->
fileName.replace("desktop_icon_$version" + "_32.png", "icon.png")
}
}
//copy executable tablexia file
copy {
from "../desktop/assets/tablexia"
into "../$packageFolder/bin/"
}
//copy control file
copy {
from "../desktop/assets"
into "../$packageFolder"
from "../desktop/assets/DEBIAN/control"
into "../$packageFolder/DEBIAN/"
}
//copy copyright file
copy {
from "../desktop/assets/copyright"
into "../$packageFolder/usr/share/doc/tablexia/"
}
//copy tablexia.desktop
copy {
from "../desktop/assets/tablexia.desktop"
into "../$packageFolder/usr/share/applications/"
}
// copy and gzip changelog
copy {
from "../desktop/assets/changelog.gz"
into "../$packageFolder/usr/share/doc/tablexia/"
}
exec {
commandLine = ['dpkg-deb',"--build","$tablexiaApp"]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment