Merge pull request #316 from afischerdev/migrate-to-android11
Migrate to gradle part 4 #315
This commit is contained in:
commit
0078f86cf6
7 changed files with 40 additions and 13 deletions
|
@ -33,6 +33,9 @@ import btools.util.StringUtils;
|
|||
|
||||
public final class OsmTrack
|
||||
{
|
||||
final public static String version = "1.6.1";
|
||||
final public static String versionDate = "01032020";
|
||||
|
||||
// csv-header-line
|
||||
private static final String MESSAGES_HEADER = "Longitude\tLatitude\tElevation\tDistance\tCostPerKm\tElevCost\tTurnCost\tNodeCost\tInitialCost\tWayTags\tNodeTags\tTime\tEnergy";
|
||||
|
||||
|
@ -444,7 +447,7 @@ public final class OsmTrack
|
|||
}
|
||||
else
|
||||
{
|
||||
sb.append( " creator=\"BRouter-1.6.1\" version=\"1.1\">\n" );
|
||||
sb.append( " creator=\"BRouter-" + version + "\" version=\"1.1\">\n" );
|
||||
}
|
||||
|
||||
if ( turnInstructionMode == 3) // osmand style
|
||||
|
@ -732,7 +735,7 @@ public final class OsmTrack
|
|||
sb.append( " {\n" );
|
||||
sb.append( " \"type\": \"Feature\",\n" );
|
||||
sb.append( " \"properties\": {\n" );
|
||||
sb.append( " \"creator\": \"BRouter-1.1\",\n" );
|
||||
sb.append( " \"creator\": \"BRouter-" + version + "\",\n" );
|
||||
sb.append( " \"name\": \"" ).append( name ).append( "\",\n" );
|
||||
sb.append( " \"track-length\": \"" ).append( distance ).append( "\",\n" );
|
||||
sb.append( " \"filtered ascend\": \"" ).append( ascend ).append( "\",\n" );
|
||||
|
|
|
@ -10,10 +10,23 @@ application {
|
|||
|
||||
jar {
|
||||
manifest {
|
||||
attributes "Main-Class": getMainClass()
|
||||
attributes "Main-Class": getMainClass(), "Implementation-Version": project.version
|
||||
}
|
||||
}
|
||||
|
||||
task fatJar(type: Jar) {
|
||||
manifest.from jar.manifest
|
||||
classifier = 'all'
|
||||
from {
|
||||
configurations.runtimeClasspath.collect { it.isDirectory() ? it : zipTree(it) }
|
||||
} {
|
||||
exclude "META-INF/*.SF"
|
||||
exclude "META-INF/*.DSA"
|
||||
exclude "META-INF/*.RSA"
|
||||
}
|
||||
with jar
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
|
|
@ -11,11 +11,11 @@ android {
|
|||
targetSdkVersion 30
|
||||
|
||||
versionCode 41
|
||||
versionName version
|
||||
versionName project.version
|
||||
|
||||
resValue('string', 'app_version', defaultConfig.versionName)
|
||||
setProperty("archivesBaseName","BRouterApp." + defaultConfig.versionName)
|
||||
|
||||
//testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
|
||||
if(project.hasProperty("RELEASE_STORE_FILE")) {
|
||||
|
|
|
@ -8,9 +8,21 @@ application {
|
|||
|
||||
jar {
|
||||
manifest {
|
||||
attributes "Main-Class": getMainClass()
|
||||
attributes "Main-Class": getMainClass(), "Implementation-Version": project.version
|
||||
}
|
||||
}
|
||||
task fatJar(type: Jar) {
|
||||
manifest.from jar.manifest
|
||||
classifier = 'all'
|
||||
from {
|
||||
configurations.runtimeClasspath.collect { it.isDirectory() ? it : zipTree(it) }
|
||||
} {
|
||||
exclude "META-INF/*.SF"
|
||||
exclude "META-INF/*.DSA"
|
||||
exclude "META-INF/*.RSA"
|
||||
}
|
||||
with jar
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
|
|
@ -9,6 +9,7 @@ import java.util.List;
|
|||
import java.io.File;
|
||||
|
||||
import btools.router.OsmNodeNamed;
|
||||
import btools.router.OsmTrack;
|
||||
import btools.router.RoutingContext;
|
||||
import btools.router.RoutingEngine;
|
||||
import btools.router.SearchBoundary;
|
||||
|
@ -89,7 +90,7 @@ public class BRouter
|
|||
}
|
||||
System.exit(0);
|
||||
}
|
||||
System.out.println("BRouter 1.6.1 / 01032020");
|
||||
System.out.println("BRouter "+ OsmTrack.version + " / " + OsmTrack.versionDate);
|
||||
if ( args.length < 6 )
|
||||
{
|
||||
System.out.println("Find routes in an OSM map");
|
||||
|
|
|
@ -327,7 +327,7 @@ public class RouteServer extends Thread implements Comparable<RouteServer>
|
|||
|
||||
public static void main(String[] args) throws Exception
|
||||
{
|
||||
System.out.println("BRouter 1.6.1 / 01032020");
|
||||
System.out.println("BRouter " + OsmTrack.version + " / " + OsmTrack.versionDate);
|
||||
if ( args.length != 5 && args.length != 6)
|
||||
{
|
||||
System.out.println("serve BRouter protocol");
|
||||
|
|
|
@ -1,9 +1,6 @@
|
|||
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
buildscript {
|
||||
|
||||
repositories {
|
||||
|
@ -11,7 +8,7 @@ buildscript {
|
|||
google()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:4.1.3'
|
||||
classpath 'com.android.tools.build:gradle:4.2.2'
|
||||
|
||||
|
||||
// NOTE: Do not place your application dependencies here; they belong
|
||||
|
@ -20,12 +17,13 @@ buildscript {
|
|||
}
|
||||
|
||||
allprojects {
|
||||
version "1.6.1"
|
||||
project.version "1.6.1"
|
||||
|
||||
repositories {
|
||||
mavenCentral()
|
||||
google()
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
task clean(type: Delete) {
|
||||
|
|
Loading…
Reference in a new issue