[arch-commits] Commit in terminator/repos/community-any (5 files)

Giancarlo Razzolini grazzolini at archlinux.org
Mon Apr 5 14:00:43 UTC 2021


    Date: Monday, April 5, 2021 @ 14:00:43
  Author: grazzolini
Revision: 911867

archrelease: copy trunk to community-any

Added:
  terminator/repos/community-any/0001-fixed-validate-module-import-for-newer-version-of-co.patch
    (from rev 911866, terminator/trunk/0001-fixed-validate-module-import-for-newer-version-of-co.patch)
  terminator/repos/community-any/PKGBUILD
    (from rev 911866, terminator/trunk/PKGBUILD)
Deleted:
  terminator/repos/community-any/0001-fixed-validate-module-import-for-newer-version-of-co.patch
  terminator/repos/community-any/0002-revert-74.patch
  terminator/repos/community-any/PKGBUILD

-----------------------------------------------------------------+
 0001-fixed-validate-module-import-for-newer-version-of-co.patch |   56 +--
 0002-revert-74.patch                                            |  159 ----------
 PKGBUILD                                                        |  102 +++---
 3 files changed, 76 insertions(+), 241 deletions(-)

Deleted: 0001-fixed-validate-module-import-for-newer-version-of-co.patch
===================================================================
--- 0001-fixed-validate-module-import-for-newer-version-of-co.patch	2021-04-05 13:59:56 UTC (rev 911866)
+++ 0001-fixed-validate-module-import-for-newer-version-of-co.patch	2021-04-05 14:00:43 UTC (rev 911867)
@@ -1,28 +0,0 @@
-From a65eb174adaa08cce0029ac38c5bc58ff8adaa7b Mon Sep 17 00:00:00 2001
-From: Ken <ken at kenh.fr>
-Date: Mon, 21 Dec 2020 19:43:06 +0100
-Subject: [PATCH] fixed 'validate' module import for newer version of configobj
-
----
- terminatorlib/config.py | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/terminatorlib/config.py b/terminatorlib/config.py
-index ec7a2a2e..ff37597d 100644
---- a/terminatorlib/config.py
-+++ b/terminatorlib/config.py
-@@ -74,7 +74,10 @@ import os
- import shutil
- from copy import copy
- from configobj import ConfigObj, flatten_errors
--from validate import Validator
-+try:
-+    from validate import Validator
-+except ModuleNotFoundError:
-+    from configobj.validate import Validator
- from .borg import Borg
- from .util import dbg, err, DEBUG, get_system_config_dir, get_config_dir, dict_diff
- 
--- 
-2.29.2
-

Copied: terminator/repos/community-any/0001-fixed-validate-module-import-for-newer-version-of-co.patch (from rev 911866, terminator/trunk/0001-fixed-validate-module-import-for-newer-version-of-co.patch)
===================================================================
--- 0001-fixed-validate-module-import-for-newer-version-of-co.patch	                        (rev 0)
+++ 0001-fixed-validate-module-import-for-newer-version-of-co.patch	2021-04-05 14:00:43 UTC (rev 911867)
@@ -0,0 +1,28 @@
+From a65eb174adaa08cce0029ac38c5bc58ff8adaa7b Mon Sep 17 00:00:00 2001
+From: Ken <ken at kenh.fr>
+Date: Mon, 21 Dec 2020 19:43:06 +0100
+Subject: [PATCH] fixed 'validate' module import for newer version of configobj
+
+---
+ terminatorlib/config.py | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/terminatorlib/config.py b/terminatorlib/config.py
+index ec7a2a2e..ff37597d 100644
+--- a/terminatorlib/config.py
++++ b/terminatorlib/config.py
+@@ -74,7 +74,10 @@ import os
+ import shutil
+ from copy import copy
+ from configobj import ConfigObj, flatten_errors
+-from validate import Validator
++try:
++    from validate import Validator
++except ModuleNotFoundError:
++    from configobj.validate import Validator
+ from .borg import Borg
+ from .util import dbg, err, DEBUG, get_system_config_dir, get_config_dir, dict_diff
+ 
+-- 
+2.29.2
+

Deleted: 0002-revert-74.patch
===================================================================
--- 0002-revert-74.patch	2021-04-05 13:59:56 UTC (rev 911866)
+++ 0002-revert-74.patch	2021-04-05 14:00:43 UTC (rev 911867)
@@ -1,159 +0,0 @@
-diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py
-index c76cd9a8..da49338c 100644
---- a/terminatorlib/terminal.py
-+++ b/terminatorlib/terminal.py
-@@ -6,7 +6,6 @@
- import os
- import signal
- import gi
--import cairo
- from gi.repository import GLib, GObject, Pango, Gtk, Gdk, GdkPixbuf
- gi.require_version('Vte', '2.91')  # vte-0.38 (gnome-3.14)
- from gi.repository import Vte
-@@ -32,32 +31,6 @@ from . import plugin
- from terminatorlib.layoutlauncher import LayoutLauncher
- from . import regex
- 
--class Overpaint(Vte.Terminal):
--    def __init__(self):
--        Vte.Terminal.__init__(self)
--        self.config = Config()
--        ### inactive_color_offset is the opposite of alpha level
--        self.dim_p = float(self.config['inactive_color_offset'])
--        self.dim_l = round(1.0 - self.dim_p,3)
--    def dim(self,b):
--        self.overpaint = b
--
--    def do_draw(self,cr):
--        ### get_color_background_for_draw is not available in older 
--        ### versions of vte
--        try:
--            bgc = Vte.Terminal.get_color_background_for_draw(self)
--        except AttributeError as e:
--            bgc = Gdk.RGBA()
--            bgc.parse(self.config['background_color'])
--        Vte.Terminal.do_draw(self,cr)
--        if self.overpaint:
--            bgc.alpha = self.dim_l
--            cr.set_operator(cairo.Operator.OVER)
--            Gdk.cairo_set_source_rgba(cr,bgc)
--            cr.rectangle(0.0,0.0,self.get_allocated_width(),self.get_allocated_height())
--            cr.paint()
--
- # pylint: disable-msg=R0904
- class Terminal(Gtk.VBox):
-     """Class implementing the VTE widget and its wrappings"""
-@@ -132,8 +105,10 @@ class Terminal(Gtk.VBox):
-     is_held_open = False
- 
-     fgcolor_active = None
-+    fgcolor_inactive = None
-     bgcolor = None
-     palette_active = None
-+    palette_inactive = None
- 
-     composite_support = None
- 
-@@ -163,9 +138,7 @@ class Terminal(Gtk.VBox):
- 
-         self.pending_on_vte_size_allocate = False
- 
--        self.vte = Overpaint()
--        self.vte.dim(False)
--        self.queue_draw()
-+        self.vte = Vte.Terminal()
-         self.background_image = None
-         if self.config['background_image'] != '':
-             try: 
-@@ -743,23 +716,58 @@ class Terminal(Gtk.VBox):
-         else:
-             self.bgcolor.alpha = 1
- 
-+        factor = self.config['inactive_color_offset']
-+        if factor > 1.0:
-+          factor = 1.0
-+        self.fgcolor_inactive = self.fgcolor_active.copy()
-+        dbg(("fgcolor_inactive set to: RGB(%s,%s,%s)", getattr(self.fgcolor_inactive, "red"),
-+                                                      getattr(self.fgcolor_inactive, "green"),
-+                                                      getattr(self.fgcolor_inactive, "blue")))
-+
-+        for bit in ['red', 'green', 'blue']:
-+            setattr(self.fgcolor_inactive, bit,
-+                    getattr(self.fgcolor_inactive, bit) * factor)
-+
-+        dbg(("fgcolor_inactive set to: RGB(%s,%s,%s)", getattr(self.fgcolor_inactive, "red"),
-+                                                      getattr(self.fgcolor_inactive, "green"),
-+                                                      getattr(self.fgcolor_inactive, "blue")))
-         colors = self.config['palette'].split(':')
-         self.palette_active = []
--
-         for color in colors:
-             if color:
-                 newcolor = Gdk.RGBA()
-                 newcolor.parse(color)
-                 self.palette_active.append(newcolor)
--        self.vte.set_colors(self.fgcolor_active, self.bgcolor,
--                                self.palette_active)
--
-+        if len(colors) == 16:
-+            # RGB values for indices 16..255 copied from vte source in order to dim them
-+            shades = [0, 95, 135, 175, 215, 255]
-+            for r in range(0, 6):
-+                for g in range(0, 6):
-+                    for b in range(0, 6):
-+                        newcolor = Gdk.RGBA()
-+                        setattr(newcolor, "red",   shades[r] / 255.0)
-+                        setattr(newcolor, "green", shades[g] / 255.0)
-+                        setattr(newcolor, "blue",  shades[b] / 255.0)
-+                        self.palette_active.append(newcolor)
-+            for y in range(8, 248, 10):
-+                newcolor = Gdk.RGBA()
-+                setattr(newcolor, "red",   y / 255.0)
-+                setattr(newcolor, "green", y / 255.0)
-+                setattr(newcolor, "blue",  y / 255.0)
-+                self.palette_active.append(newcolor)
-+        self.palette_inactive = []
-+        for color in self.palette_active:
-+            newcolor = Gdk.RGBA()
-+            for bit in ['red', 'green', 'blue']:
-+                setattr(newcolor, bit,
-+                        getattr(color, bit) * factor)
-+            self.palette_inactive.append(newcolor)
-         if self.terminator.last_focused_term == self:
--            self.vte.dim(False)
--            self.queue_draw()
-+            self.vte.set_colors(self.fgcolor_active, self.bgcolor,
-+                                self.palette_active)
-         else:
--            self.vte.dim(True)
--            self.queue_draw()
-+            self.vte.set_colors(self.fgcolor_inactive, self.bgcolor,
-+                                self.palette_inactive)
-         profiles = self.config.base.profiles
-         terminal_box_style_context = self.terminalbox.get_style_context()
-         for profile in list(profiles.keys()):
-@@ -1265,8 +1273,9 @@ class Terminal(Gtk.VBox):
- 
-     def on_vte_focus_in(self, _widget, _event):
-         """Inform other parts of the application when focus is received"""
--        self.vte.dim(False)
--        self.queue_draw()
-+        self.vte.set_colors(self.fgcolor_active, self.bgcolor,
-+                            self.palette_active)
-+        self.set_cursor_color()
-         if not self.terminator.doing_layout:
-             self.terminator.last_focused_term = self
-             if self.get_toplevel().is_child_notebook():
-@@ -1280,8 +1289,9 @@ class Terminal(Gtk.VBox):
- 
-     def on_vte_focus_out(self, _widget, _event):
-         """Inform other parts of the application when focus is lost"""
--        self.vte.dim(True)
--        self.queue_draw()
-+        self.vte.set_colors(self.fgcolor_inactive, self.bgcolor,
-+                            self.palette_inactive)
-+        self.set_cursor_color()
-         self.emit('focus-out')
- 
-     def on_window_focus_out(self):
-

Deleted: PKGBUILD
===================================================================
--- PKGBUILD	2021-04-05 13:59:56 UTC (rev 911866)
+++ PKGBUILD	2021-04-05 14:00:43 UTC (rev 911867)
@@ -1,54 +0,0 @@
-# Maintainer: Giancarlo Razzolini <grazzolini at archlinux.org>
-# Contributor: Guillaume ALAUX <guillaume at archlinux.org>
-# Contributor: Allan McRae <allan at archlinux.org>
-# Contributor: fancris3 <fancris3 at gmail.com>
-# Contributor: Daniel J Griffiths <ghost1227 at archlinux.us>
-
-pkgname=terminator
-pkgver=2.1.1
-pkgrel=1
-pkgdesc='Terminal emulator that supports tabs and grids'
-arch=('any')
-url='https://github.com/gnome-terminator/terminator'
-license=('GPL2')
-depends=('gsettings-desktop-schemas' 'libkeybinder3' 'libnotify' 'python-cairo' 'python-configobj'
-         'python-dbus' 'python-psutil' 'python-gobject' 'vte3' 'xdg-utils')
-makedepends=('intltool' 'python-pip' 'python-setuptools' 'python-wheel')
-source=(${url}/releases/download/v${pkgver}/${pkgname}-${pkgver}.tar.gz{,.asc}
-        0001-fixed-validate-module-import-for-newer-version-of-co.patch
-        0002-revert-74.patch)
-
-validpgpkeys=('6FBDB41587919A0F4BA96EBA9A358BAB04A4ED27'  #Markus Frosch <markus at lazyfrosch.de>
-              'D11A7596F61705480C711598F2FAC7C7BAE930A5') #Matt Rose <mattrose at folkwolf.net>
-md5sums=('a22e65eae47b34ccd42055725573bbb9'
-         'SKIP'
-         '585159c653affe58d99bb4858360f21b'
-         '076af1e87d70a2a3592b2ce280d1117b')
-sha512sums=('a916b9718801bb015d14bdec2eede24c89101d5ea36d22131b7d34f8dad48b9db9e79811645ce571e3c95c9e4b2f18d6b8508f519de7ff54c4246c5f7b546af2'
-            'SKIP'
-            'da609bbb1f2fce64bd345ec43c05f6b8d76046cfbd1be764d6fcd555d306dfca1dd5786b0fc65c0984e49a85454c9eeabf5a1f8c960412c14a97c5350912f8a9'
-            '347cb209564939b7248e0f925001bcdbf5c6f15686d5e40c0a2b43ced3b19112ef06ba19904a16d8fddd82d5cfb70ab95ad96a61a9fe656822423abc7517beba')
-
-prepare () {
-    cd "${srcdir}/${pkgname}-${pkgver}"
-
-    #Fix for python configobj validate
-    patch -Np1 < $srcdir/0001-fixed-validate-module-import-for-newer-version-of-co.patch
-
-    #Revert fix issue #74
-    #patch -Np1 < $srcdir/0002-revert-74.patch
-}
-
-build() {
-    cd "${srcdir}/${pkgname}-${pkgver}"
-
-    python setup.py build
-}
-
-package() {
-    cd "${srcdir}/${pkgname}-${pkgver}"
-
-    python setup.py install --skip-build --root="${pkgdir}" --optimize=1
-
-    rm -f "${pkgdir}/usr/share/icons/hicolor/icon-theme.cache"
-}

Copied: terminator/repos/community-any/PKGBUILD (from rev 911866, terminator/trunk/PKGBUILD)
===================================================================
--- PKGBUILD	                        (rev 0)
+++ PKGBUILD	2021-04-05 14:00:43 UTC (rev 911867)
@@ -0,0 +1,48 @@
+# Maintainer: Giancarlo Razzolini <grazzolini at archlinux.org>
+# Contributor: Guillaume ALAUX <guillaume at archlinux.org>
+# Contributor: Allan McRae <allan at archlinux.org>
+# Contributor: fancris3 <fancris3 at gmail.com>
+# Contributor: Daniel J Griffiths <ghost1227 at archlinux.us>
+
+pkgname=terminator
+pkgver=2.1.1
+pkgrel=2
+pkgdesc='Terminal emulator that supports tabs and grids'
+arch=('any')
+url='https://github.com/gnome-terminator/terminator'
+license=('GPL2')
+depends=('gsettings-desktop-schemas' 'libkeybinder3' 'libnotify' 'python-cairo' 'python-configobj'
+         'python-dbus' 'python-psutil' 'python-gobject' 'vte3' 'xdg-utils')
+makedepends=('intltool' 'python-pip' 'python-setuptools' 'python-wheel')
+source=(${url}/releases/download/v${pkgver}/${pkgname}-${pkgver}.tar.gz{,.asc}
+        0001-fixed-validate-module-import-for-newer-version-of-co.patch)
+
+validpgpkeys=('6FBDB41587919A0F4BA96EBA9A358BAB04A4ED27'  #Markus Frosch <markus at lazyfrosch.de>
+              'D11A7596F61705480C711598F2FAC7C7BAE930A5') #Matt Rose <mattrose at folkwolf.net>
+md5sums=('a22e65eae47b34ccd42055725573bbb9'
+         'SKIP'
+         '585159c653affe58d99bb4858360f21b')
+sha512sums=('a916b9718801bb015d14bdec2eede24c89101d5ea36d22131b7d34f8dad48b9db9e79811645ce571e3c95c9e4b2f18d6b8508f519de7ff54c4246c5f7b546af2'
+            'SKIP'
+            'da609bbb1f2fce64bd345ec43c05f6b8d76046cfbd1be764d6fcd555d306dfca1dd5786b0fc65c0984e49a85454c9eeabf5a1f8c960412c14a97c5350912f8a9')
+
+prepare () {
+    cd "${srcdir}/${pkgname}-${pkgver}"
+
+    #Fix for python configobj validate
+    patch -Np1 < $srcdir/0001-fixed-validate-module-import-for-newer-version-of-co.patch
+}
+
+build() {
+    cd "${srcdir}/${pkgname}-${pkgver}"
+
+    python setup.py build
+}
+
+package() {
+    cd "${srcdir}/${pkgname}-${pkgver}"
+
+    python setup.py install --skip-build --root="${pkgdir}" --optimize=1
+
+    rm -f "${pkgdir}/usr/share/icons/hicolor/icon-theme.cache"
+}



More information about the arch-commits mailing list