[syncany] 10/10: Add startup-script and fix the sy and syncany script which would emit

Markus Koschany apo-guest at moszumanska.debian.org
Wed Jan 25 01:48:43 UTC 2017


This is an automated email from the git hooks/post-receive script.

apo-guest pushed a commit to branch master
in repository syncany.

commit 7614bf3d099f24caaeedb783094277dc682027df
Author: Markus Koschany <apo at debian.org>
Date:   Wed Jan 25 02:37:56 2017 +0100

    Add startup-script and fix the sy and syncany script which would emit
    
    error messages with other shells than bash.
---
 debian/changelog                    |  2 ++
 debian/patches/series               |  1 +
 debian/patches/startup-script.patch | 25 +++++++++++++++++++++++++
 3 files changed, 28 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 50b0ccb..d6728e0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,6 +4,8 @@ syncany (0.4.9~alpha-1) experimental; urgency=medium
   * Update copyright years.
   * Refresh all patches for new release.
   * Tighten dependency on JRE. Syncany requires Java 8 at least.
+  * Add startup-script and fix the sy and syncany script which would emit error
+    messages with other shells than bash.
 
  -- Markus Koschany <apo at debian.org>  Wed, 25 Jan 2017 01:33:41 +0100
 
diff --git a/debian/patches/series b/debian/patches/series
index 3cd474b..302af7c 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
 applicationVersion.patch
 build.patch
 no-tests.patch
+startup-script.patch
diff --git a/debian/patches/startup-script.patch b/debian/patches/startup-script.patch
new file mode 100644
index 0000000..1f2cb9f
--- /dev/null
+++ b/debian/patches/startup-script.patch
@@ -0,0 +1,25 @@
+From: Markus Koschany <apo at debian.org>
+Date: Wed, 25 Jan 2017 02:34:09 +0100
+Subject: startup script
+
+Gradle's createStartScript task no longer changes the shebang to point to bash
+but to the generic sh instead. However the start script uses bash specific
+expressions like [[ which will cause warnings or errors with other shells.
+Let's fix this by using the common [ and = expression.
+---
+ gradle/gradle/application.distribution.gradle | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gradle/gradle/application.distribution.gradle b/gradle/gradle/application.distribution.gradle
+index a6316b9..1fb66a0 100644
+--- a/gradle/gradle/application.distribution.gradle
++++ b/gradle/gradle/application.distribution.gradle
+@@ -137,7 +137,7 @@ startScripts {
+ 		unixClassPathCommands += "for LIB_GLOBAL in \$LIBS_GLOBAL; do\n"
+ 		unixClassPathCommands += "	LIB_GLOBAL_BASENAME=\$(basename \$LIB_GLOBAL)\n"
+ 		unixClassPathCommands += "\n"
+-		unixClassPathCommands += "	if [[ \$LIB_GLOBAL_BASENAME == syncany-plugin-*.jar ]]; then\n"
++		unixClassPathCommands += "	if [ \"\$LIB_GLOBAL_BASENAME\" = syncany-plugin-*.jar ]; then\n"
+ 		unixClassPathCommands += "		PLUGIN_JAR_PREFIX=\$(expr match \"\$LIB_GLOBAL_BASENAME\" '\\(syncany-plugin-[^-]*-\\)')\n"
+ 		unixClassPathCommands += "		IN_USER_PLUGINS=\$(ls \$APP_USERCONFIG_DIR/plugins/lib/\$PLUGIN_JAR_PREFIX*.jar 2> /dev/null)\n"
+ 		unixClassPathCommands += "\n"

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/syncany.git



More information about the pkg-java-commits mailing list