[gnome-documents] gnome-documents.in: Use shorter syntax for LD_LIBRARY_PATH etc. fiddling
- From: Colin Walters <walters src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-documents] gnome-documents.in: Use shorter syntax for LD_LIBRARY_PATH etc. fiddling
- Date: Wed, 5 Dec 2012 19:39:34 +0000 (UTC)
commit 2534ac71fc7f931d139ae0d6206b5a48d0a60616
Author: Colin Walters <walters verbum org>
Date: Wed Dec 5 14:32:08 2012 -0500
gnome-documents.in: Use shorter syntax for LD_LIBRARY_PATH etc. fiddling
This is one line vs 5.
https://bugzilla.gnome.org/show_bug.cgi?id=689727
src/gnome-documents-search-provider.in | 20 +++-----------------
src/gnome-documents.in | 20 +++-----------------
2 files changed, 6 insertions(+), 34 deletions(-)
---
diff --git a/src/gnome-documents-search-provider.in b/src/gnome-documents-search-provider.in
index cc0f90a..36e9968 100644
--- a/src/gnome-documents-search-provider.in
+++ b/src/gnome-documents-search-provider.in
@@ -1,21 +1,7 @@
#!/bin/sh
-if test x"$GJS_PATH" = x ; then
- export GJS_PATH= pkgdatadir@/js
-else
- export GJS_PATH= pkgdatadir@/js:$GJS_PATH
-fi
-
-if test x"$GI_TYPELIB_PATH" = x ; then
- export GI_TYPELIB_PATH= pkglibdir@/girepository-1.0
-else
- export GI_TYPELIB_PATH= pkglibdir@/girepository-1.0:$GI_TYPELIB_PATH
-fi
-
-if test x"$LD_LIBRARY_PATH" = x ; then
- export LD_LIBRARY_PATH= pkglibdir@
-else
- export LD_LIBRARY_PATH= pkglibdir@:$LD_LIBRARY_PATH
-fi
+export GJS_PATH="@pkgdatadir@/js${GJS_PATH:+:GJS_PATH}"
+export GI_TYPELIB_PATH="@pkglibdir@/girepository-1.0${GI_TYPELIB_PATH:+:GI_TYPELIB_PATH}"
+export LD_LIBRARY_PATH="@pkglibdir ${LD_LIBRARY_PATH:+:LD_LIBRARY_PATH}"
@GJS_CONSOLE@ -I @pkgdatadir@/js -c "const SearchProvider = imports.shellSearchProvider; SearchProvider.start();"
diff --git a/src/gnome-documents.in b/src/gnome-documents.in
index 28b0184..211703d 100644
--- a/src/gnome-documents.in
+++ b/src/gnome-documents.in
@@ -1,22 +1,8 @@
#!/bin/sh
-if test x"$GJS_PATH" = x ; then
- export GJS_PATH= pkgdatadir@/js
-else
- export GJS_PATH= pkgdatadir@/js:$GJS_PATH
-fi
-
-if test x"$GI_TYPELIB_PATH" = x ; then
- export GI_TYPELIB_PATH= pkglibdir@/girepository-1.0
-else
- export GI_TYPELIB_PATH= pkglibdir@/girepository-1.0:$GI_TYPELIB_PATH
-fi
-
-if test x"$LD_LIBRARY_PATH" = x ; then
- export LD_LIBRARY_PATH= pkglibdir@
-else
- export LD_LIBRARY_PATH= pkglibdir@:$LD_LIBRARY_PATH
-fi
+export GJS_PATH="@pkgdatadir@/js${GJS_PATH:+:GJS_PATH}"
+export GI_TYPELIB_PATH="@pkglibdir@/girepository-1.0${GI_TYPELIB_PATH:+:GI_TYPELIB_PATH}"
+export LD_LIBRARY_PATH="@pkglibdir ${LD_LIBRARY_PATH:+:LD_LIBRARY_PATH}"
if test x"$GJS_DEBUG_OUTPUT" = x ; then
export GJS_DEBUG_OUTPUT=stderr
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]