[Android] Check VLC git revision in libvlc

Geoffrey Métais git at videolan.org
Mon Dec 10 10:31:24 CET 2018


vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Mon Dec 10 10:17:29 2018 +0100| [bdb276d2632983fc8cb85bad2a174cdbf22438a7] | committer: Geoffrey Métais

Check VLC git revision in libvlc

> https://code.videolan.org/videolan/vlc-android/commit/bdb276d2632983fc8cb85bad2a174cdbf22438a7
---

 libvlc/build.gradle      | 10 ++++++++++
 vlc-android/build.gradle | 11 -----------
 2 files changed, 10 insertions(+), 11 deletions(-)

diff --git a/libvlc/build.gradle b/libvlc/build.gradle
index 8aaf2a9d2..5aa161352 100644
--- a/libvlc/build.gradle
+++ b/libvlc/build.gradle
@@ -16,6 +16,7 @@ android {
         compileSdkVersion rootProject.ext.compileSdkVersion
         targetSdkVersion rootProject.ext.targetSdkVersion
         minSdkVersion rootProject.ext.minSdkVersion
+        resValue "string", "build_vlc_revision", vlcRevision()
     }
 
     sourceSets {
@@ -63,4 +64,13 @@ dependencies {
     api "androidx.legacy:legacy-support-v4:$rootProject.ext.androidxVersion"
 }
 
+def vlcRevision() {
+    def vlc = new ByteArrayOutputStream()
+    exec {
+        commandLine 'git', 'rev-parse', '--short', 'HEAD'
+        standardOutput = vlc
+    }
+    return vlc.toString()
+}
+
 apply from: '../publish.gradle'
diff --git a/vlc-android/build.gradle b/vlc-android/build.gradle
index dc770890f..7af9ec37b 100644
--- a/vlc-android/build.gradle
+++ b/vlc-android/build.gradle
@@ -51,7 +51,6 @@ android {
         resValue "string", "build_time", buildTime()
         resValue "string", "build_host", hostName()
         resValue "string", "build_revision", revision()
-        resValue "string", "build_vlc_revision", vlcRevision()
 
         testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
         // The following argument makes the Android Test Orchestrator run its
@@ -255,13 +254,3 @@ def revision() {
     }
     return code.toString()
 }
-
-def vlcRevision() {
-    def vlc = new ByteArrayOutputStream()
-    exec {
-        commandLine 'git', 'rev-parse', '--short', 'HEAD'
-        workingDir '../vlc'
-        standardOutput = vlc
-    }
-    return vlc.toString()
-}



More information about the Android mailing list