[zeroinstall-injector] Fix --versions handling of 0alias-generated launchers

Michel Alexandre Salim salimma at fedoraproject.org
Wed Jun 22 13:17:40 UTC 2011


commit 9527bba711e94d1c669a762206e5e96651710e4e
Author: Michel Alexandre Salim <michel.salim at cs.fau.de>
Date:   Wed Jun 22 15:17:16 2011 +0200

    Fix --versions handling of 0alias-generated launchers

 zeroinstall-injector-1.0-fix-versions.patch |   31 +++++++++++++++++++++++++++
 zeroinstall-injector.spec                   |   10 +++++++-
 2 files changed, 39 insertions(+), 2 deletions(-)
---
diff --git a/zeroinstall-injector-1.0-fix-versions.patch b/zeroinstall-injector-1.0-fix-versions.patch
new file mode 100644
index 0000000..b3a25df
--- /dev/null
+++ b/zeroinstall-injector-1.0-fix-versions.patch
@@ -0,0 +1,31 @@
+--- zeroinstall-injector-1.0/zeroinstall/alias.py.fix-versions	2011-05-23 10:10:43.000000000 +0200
++++ zeroinstall-injector-1.0/zeroinstall/alias.py	2011-06-22 14:46:56.457683015 +0200
+@@ -10,7 +10,7 @@
+ 
+ _template = '''#!/bin/sh
+ if [ "$*" = "--versions" ]; then
+-  exec 0launch -gd '%s' "$@"
++  exec 0launch -gd '%s'
+ else
+   exec 0launch %s '%s' "$@"
+ fi
+--- zeroinstall-injector-1.0/tests/testalias.py.fix-versions	2011-05-23 10:10:43.000000000 +0200
++++ zeroinstall-injector-1.0/tests/testalias.py	2011-06-22 14:58:48.609768005 +0200
+@@ -10,7 +10,7 @@
+ 
+ expected_script = """#!/bin/sh
+ if [ "$*" = "--versions" ]; then
+-  exec 0launch -gd 'http://example.com/foo.xml' "$@"
++  exec 0launch -gd 'http://example.com/foo.xml'
+ else
+   exec 0launch  'http://example.com/foo.xml' "$@"
+ fi
+@@ -18,7 +18,7 @@
+ 
+ expected_script_main = """#!/bin/sh
+ if [ "$*" = "--versions" ]; then
+-  exec 0launch -gd 'http://example.com/foo.xml' "$@"
++  exec 0launch -gd 'http://example.com/foo.xml'
+ else
+   exec 0launch --main 'a'\\'''\\''\\test' 'http://example.com/foo.xml' "$@"
+ fi
diff --git a/zeroinstall-injector.spec b/zeroinstall-injector.spec
index 796bc8e..532bc37 100644
--- a/zeroinstall-injector.spec
+++ b/zeroinstall-injector.spec
@@ -5,13 +5,15 @@
 
 Name:    zeroinstall-injector
 Version: 1.0
-Release: 2%{?dist}
+Release: 3%{?dist}
 Summary: The Zero Install Injector (0launch)
 
 Group:   Applications/System
 License: LGPLv2
 URL:     http://0install.net
 Source0: http://downloads.sourceforge.net/project/zero-install/injector/%{version}/%{name}-%{version}.tar.bz2
+# https://sourceforge.net/tracker/?func=detail&aid=3324502&group_id=76468&atid=547191
+Patch0:	 %{name}-1.0-fix-versions.patch
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildArch: noarch
@@ -54,7 +56,8 @@ automatically check for updates when software is run.
 
 %prep
 %setup -q -n %{name}-%{version}
-#patch0 -p1 -b .any-arch
+
+%patch0 -p1 -b .fix-versions
 
 %build
 %{__python} setup.py build
@@ -129,6 +132,9 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
 %attr(755,zeroinst,zeroinst) %{cache_dir}/implementations
 
 %changelog
+* Wed Jun 22 2011 Michel Salim <salimma at fedoraproject.org> - 1.0-3
+- Fix --versions handling of 0alias-generated launchers
+
 * Wed Jun 15 2011 Michel Salim <salimma at fedoraproject.org> - 1.0-2
 - Add main category "System" to desktop entries
 


More information about the scm-commits mailing list