Hello community, here is the log from the commit of package terminator for openSUSE:Factory checked in at 2020-01-19 20:56:23 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/terminator (Old) and /work/SRC/openSUSE:Factory/.terminator.new.26092 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "terminator" Sun Jan 19 20:56:23 2020 rev:16 rq:765457 version:1.91 Changes: -------- --- /work/SRC/openSUSE:Factory/terminator/terminator.changes 2018-08-27 13:00:23.116884003 +0200 +++ /work/SRC/openSUSE:Factory/.terminator.new.26092/terminator.changes 2020-01-19 20:58:05.424070826 +0100 @@ -1,0 +2,9 @@ +Sat Jan 18 09:12:15 UTC 2020 - Kristyna Streitova <[email protected]> + +- add terminator-1.91-python3.patch to add python3 support +- add terminator-1.91-py3_dnd.patch to fix url drag and drop +- add missing Requires: python3-configobj +- use python3 variants of BuildRequires, Requires and macros +- update URL (.cz -> .com) + +------------------------------------------------------------------- New: ---- terminator-1.91-py3_dnd.patch terminator-1.91-python3.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ terminator.spec ++++++ --- /var/tmp/diff_new_pack.bwdD2m/_old 2020-01-19 20:58:06.040071149 +0100 +++ /var/tmp/diff_new_pack.bwdD2m/_new 2020-01-19 20:58:06.040071149 +0100 @@ -1,7 +1,7 @@ # # spec file for package terminator # -# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -23,21 +23,24 @@ Summary: Store and run multiple GNOME terminals in one window License: GPL-2.0-only Group: System/X11/Terminals -URL: https://gnometerminator.blogspot.cz/p/introduction.html +URL: https://gnometerminator.blogspot.com/p/introduction.html Source0: https://launchpad.net/%{name}/gtk3/%{version}/+download/%{name}-%{version}.tar.gz Patch0: terminator-desktop.patch +Patch1: terminator-1.91-python3.patch +Patch2: terminator-1.91-py3_dnd.patch BuildRequires: desktop-file-utils BuildRequires: fdupes BuildRequires: gettext BuildRequires: gobject-introspection BuildRequires: hicolor-icon-theme BuildRequires: intltool -BuildRequires: python-devel +BuildRequires: python3-devel BuildRequires: update-desktop-files -Requires: python-cairo -Requires: python-gobject -Requires: python-gobject-Gdk -Requires: python-psutil +Requires: python3-cairo +Requires: python3-configobj +Requires: python3-gobject +Requires: python3-gobject-Gdk +Requires: python3-psutil Requires(post): hicolor-icon-theme Requires(postun): hicolor-icon-theme Recommends: %{name}-lang @@ -54,16 +57,18 @@ %prep %setup -q -%patch0 +%patch0 -p0 +%patch1 -p1 +%patch2 -p0 # remove pointless shebangs sed -i '/#! \?\/usr.*/d' terminatorlib/*.py %build -python setup.py build +python3 setup.py build %install -python setup.py install --root=%{buildroot} --prefix=%{_prefix} +python3 setup.py install --root=%{buildroot} --prefix=%{_prefix} rm -f %{buildroot}/%{_datadir}/icons/hicolor/icon-theme.cache rm -f %{buildroot}/%{_datadir}/applications/%{name}.desktop @@ -106,7 +111,7 @@ %{_bindir}/remotinator %{_mandir}/man1/%{name}.* %{_mandir}/man5/%{name}_config.* -%{python_sitelib}/* +%{python3_sitelib}/* %dir %{_datadir}/appdata/ %{_datadir}/appdata/%{name}.appdata.xml %{_datadir}/applications/%{name}.desktop ++++++ terminator-1.91-py3_dnd.patch ++++++ === modified file 'terminatorlib/terminal.py' --- terminatorlib/terminal.py 2019-10-21 21:36:16 +0000 +++ terminatorlib/terminal.py 2019-11-15 19:47:49 +0000 @@ -1093,30 +1093,35 @@ dbg('drag data received of type: %s' % (selection_data.get_data_type())) if Gtk.targets_include_text(drag_context.list_targets()) or \ Gtk.targets_include_uri(drag_context.list_targets()): - # copy text with no modification yet to destination - txt = selection_data.get_data() - # https://bugs.launchpad.net/terminator/+bug/1518705 if info == self.TARGET_TYPE_MOZ: - txt = txt.decode('utf-16').encode('utf-8') - txt = txt.split('\n')[0] - - txt_lines = txt.split( "\r\n" ) - if txt_lines[-1] == '': - for line in txt_lines[:-1]: - if line[0:7] != 'file://': - txt = txt.replace('\r\n','\n') - break - else: - # It is a list of crlf terminated file:// URL. let's - # iterate over all elements except the last one. - str='' - for fname in txt_lines[:-1]: - dbg('drag data fname: %s' % fname) - fname = "'%s'" % urllib.parse.unquote(fname[7:].replace("'", - '\'\\\'\'')) - str += fname + ' ' - txt=str + # TYPE_MOZ is two lines encoded in UTF-16: the URL and the visible text. Ignore the latter. + # https://bugs.launchpad.net/terminator/+bug/1518705 + txt = selection_data.get_data().decode('utf-16') + txt = txt.split('\n')[0] + else: + # Other types are encoded in UTF-8. + txt = selection_data.get_data().decode() + + # File managers send CRLF terminated list of filenames. + # Convert them to space separated, quoted for shell command line. + txt_lines = txt.split( "\r\n" ) + if txt_lines[-1] == '': + for line in txt_lines[:-1]: + if line[0:7] != 'file://': + txt = txt.replace('\r\n', '\n') + break + else: + # It is a list of crlf terminated file:// URL. Let's + # iterate over all elements except the last one. + str = '' + for fname in txt_lines[:-1]: + dbg('drag data fname: %s' % fname) + fname = "'%s'" % urllib.parse.unquote(fname[7:].replace("'", + '\'\\\'\'')) + str += fname + ' ' + txt = str + for term in self.terminator.get_target_terms(self): term.feed(txt) return @@ -1513,7 +1518,8 @@ def feed(self, text): """Feed the supplied text to VTE""" - self.vte.feed_child(text, len(text)) + # See https://gitlab.gnome.org/GNOME/vte/issues/201. + self.vte.feed_child_binary(text.encode(self.vte.get_encoding())) def zoom_in(self): """Increase the font size""" ++++++ terminator-1.91-python3.patch ++++++ ++++ 13476 lines (skipped)
