diff options
author | Patrick McLean <patrick.mclean@sony.com> | 2020-12-21 10:54:36 -0800 |
---|---|---|
committer | Patrick McLean <chutzpah@gentoo.org> | 2020-12-21 12:20:27 -0800 |
commit | 0032389fbc8849685b4fc02965d4500dcba2d6c1 (patch) | |
tree | f68fed6aea7a459acbbd04807ecad921c3c10c52 /sys-process | |
parent | sys-cluster/ceph-14.2.16: Version bump (diff) | |
download | gentoo-0032389fbc8849685b4fc02965d4500dcba2d6c1.tar.gz gentoo-0032389fbc8849685b4fc02965d4500dcba2d6c1.tar.bz2 gentoo-0032389fbc8849685b4fc02965d4500dcba2d6c1.zip |
sys-process/bpytop: New package
Copyright: Sony Interactive Entertainment Inc.
Package-Manager: Portage-3.0.12, Repoman-3.0.2
Signed-off-by: Patrick McLean <chutzpah@gentoo.org>
Diffstat (limited to 'sys-process')
-rw-r--r-- | sys-process/bpytop/Manifest | 1 | ||||
-rw-r--r-- | sys-process/bpytop/bpytop-1.0.51.ebuild | 27 | ||||
-rw-r--r-- | sys-process/bpytop/files/bpytop-1.0.51-tests.patch | 45 | ||||
-rw-r--r-- | sys-process/bpytop/metadata.xml | 8 |
4 files changed, 81 insertions, 0 deletions
diff --git a/sys-process/bpytop/Manifest b/sys-process/bpytop/Manifest new file mode 100644 index 000000000000..941d914f3f86 --- /dev/null +++ b/sys-process/bpytop/Manifest @@ -0,0 +1 @@ +DIST bpytop-1.0.51.tar.gz 616001 BLAKE2B 1155af6d25367b65064039bc46a5f8786d5107e12f9a1280da59f1fb696c3abe99f200126b2107ead4d9ca50ba6e6eeabe79d6e8e247aa4c0be87b952f142655 SHA512 a7157a3e33e5465e406f7930457a6821d8e2b45aca0f0283e7f2e3a8d29f3a6be8c7042380c66bd5ee227b067e6c643ac034b2d02168fe530d02f1eddece6e2d diff --git a/sys-process/bpytop/bpytop-1.0.51.ebuild b/sys-process/bpytop/bpytop-1.0.51.ebuild new file mode 100644 index 000000000000..0621a07dc62f --- /dev/null +++ b/sys-process/bpytop/bpytop-1.0.51.ebuild @@ -0,0 +1,27 @@ +# Copyright 2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{6..9} ) +DISTUTILS_USE_SETUPTOOLS=pyproject.toml +inherit distutils-r1 + +DESCRIPTION="Linux/OSX/FreeBSD resource monitor" +HOMEPAGE="https://github.com/aristocratos/bpytop" +SRC_URI="https://github.com/aristocratos/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="test" + +RDEPEND=" + >=dev-python/psutil-5.7.1[${PYTHON_USEDEP}] +" + +distutils_enable_tests pytest + +PATCHES=( + "${FILESDIR}/bpytop-1.0.51-tests.patch" +) diff --git a/sys-process/bpytop/files/bpytop-1.0.51-tests.patch b/sys-process/bpytop/files/bpytop-1.0.51-tests.patch new file mode 100644 index 000000000000..3e5de4751fd9 --- /dev/null +++ b/sys-process/bpytop/files/bpytop-1.0.51-tests.patch @@ -0,0 +1,45 @@ +diff --git a/bpytop.py b/bpytop.py +index a1c2b3a..b1cc28e 100755 +--- a/bpytop.py ++++ b/bpytop.py +@@ -64,23 +64,27 @@ args.add_argument("-p" , "--proc" ,action="store_true" ,help ="Start in minimal + args.add_argument("-s" , "--stat" ,action="store_true" ,help ="Start in minimal mode without process box") + args.add_argument("-v" , "--version" ,action="store_true" ,help ="Show version info and exit") + args.add_argument("--debug" ,action="store_true" ,help ="Start with loglevel set to DEBUG overriding value set in config") +-stdargs = args.parse_args() +- +-if stdargs.version: +- print(f'bpytop version: {VERSION}\n' +- f'psutil version: {".".join(str(x) for x in psutil.version_info)}') +- raise SystemExit(0) + + ARG_MODE: str = "" + +-if stdargs.full: +- ARG_MODE = "full" +-elif stdargs.proc: +- ARG_MODE = "proc" +-elif stdargs.stat: +- ARG_MODE = "stat" ++if __name__ == "__main__": ++ stdargs = args.parse_args() ++ ++ if stdargs.version: ++ print(f'bpytop version: {VERSION}\n' ++ f'psutil version: {".".join(str(x) for x in psutil.version_info)}') ++ raise SystemExit(0) + +-DEBUG = stdargs.debug ++ if stdargs.full: ++ ARG_MODE = "full" ++ elif stdargs.proc: ++ ARG_MODE = "proc" ++ elif stdargs.stat: ++ ARG_MODE = "stat" ++ ++ DEBUG = stdargs.debug ++else: ++ DEBUG = False + + #? Variables -------------------------------------------------------------------------------------> + diff --git a/sys-process/bpytop/metadata.xml b/sys-process/bpytop/metadata.xml new file mode 100644 index 000000000000..cee379b15409 --- /dev/null +++ b/sys-process/bpytop/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>chutzpah@gentoo.org</email> + <name>Patrick McLean</name> + </maintainer> +</pkgmetadata> |