svn commit: r519957 - in head/sysutils/hatop: . files
Koichiro Iwao
meta at FreeBSD.org
Fri Dec 13 00:09:03 UTC 2019
Author: meta
Date: Fri Dec 13 00:09:02 2019
New Revision: 519957
URL: https://svnweb.freebsd.org/changeset/ports/519957
Log:
sysutils/hatop: actually works with Python 2.7
Also, fix for terminals larger than 80x25 on Python 3.
PR: 242590
Submitted by: meta (myself), maintainer
Reviewed by: maintainer
Modified:
head/sysutils/hatop/Makefile
head/sysutils/hatop/files/patch-bin_hatop
Modified: head/sysutils/hatop/Makefile
==============================================================================
--- head/sysutils/hatop/Makefile Thu Dec 12 23:41:16 2019 (r519956)
+++ head/sysutils/hatop/Makefile Fri Dec 13 00:09:02 2019 (r519957)
@@ -3,7 +3,7 @@
PORTNAME= hatop
PORTVERSION= 0.7.7
-PORTREVISION= 4
+PORTREVISION= 5
DISTVERSIONPREFIX= v
CATEGORIES= sysutils net
@@ -14,7 +14,7 @@ LICENSE= GPLv3+
RUN_DEPENDS= ${LOCALBASE}/sbin/haproxy:net/haproxy
-USES= python:3.6+ shebangfix
+USES= python:2.7+ shebangfix
SHEBANG_FILES= bin/hatop
NO_BUILD= yes
NO_ARCH= yes
Modified: head/sysutils/hatop/files/patch-bin_hatop
==============================================================================
--- head/sysutils/hatop/files/patch-bin_hatop Thu Dec 12 23:41:16 2019 (r519956)
+++ head/sysutils/hatop/files/patch-bin_hatop Fri Dec 13 00:09:02 2019 (r519957)
@@ -153,6 +153,15 @@
def get_width(width, xmax, ncols, idx):
# distribute excess space evenly from left to right
+@@ -1709,7 +1709,7 @@ def get_width(width, xmax, ncols, idx):
+ if idx < (xdiff - (xdiff / ncols) * ncols):
+ width += 1 # compensate rounding
+ width = width + xdiff / ncols
+- return width
++ return int(width)
+
+ def get_cell(width, align, value):
+ s = str(value)
@@ -1732,7 +1732,7 @@ def get_head(mode):
def get_screenlines(stat):
screenlines = []
More information about the svn-ports-all
mailing list