aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormiwi <miwi@FreeBSD.org>2018-07-28 20:21:38 +0800
committermiwi <miwi@FreeBSD.org>2018-07-28 20:21:38 +0800
commit7a1eeb492e9fd41da27f3f51873b532d0a6cd7cf (patch)
tree6e1b21c68ce87ba039d072fbc35989eabbdd6779
parent31ca5446fa3fb1c45276cec8c267a0e8be3732bb (diff)
downloadfreebsd-ports-gnome-7a1eeb492e9fd41da27f3f51873b532d0a6cd7cf.tar.gz
freebsd-ports-gnome-7a1eeb492e9fd41da27f3f51873b532d0a6cd7cf.tar.zst
freebsd-ports-gnome-7a1eeb492e9fd41da27f3f51873b532d0a6cd7cf.zip
Commons of Python micro-functions. This is basically an out-sourced, shared
utils module. Rules: - Must work in Python 2 and Python 3 - Cannot depend on anything but six and the standard library Functions: - is_sequence: check if something is list-ish - is_mapping: check if an object is dict-ish - ensure_list: make sure an argument is a list, or make it into a single-element list - clean_dict: remove null values from a dict, recursively - decode_path: decode a path name to be unicode - hash_data: generate a SHA1 from a dict of reasonable objects WWW: https://github.com/pudo/banal PR: 229526 Submitted by: freebsd_ports@k-worx.org Sponsored by: iXsystems Inc.
-rw-r--r--devel/Makefile1
-rw-r--r--devel/py-banal/Makefile22
-rw-r--r--devel/py-banal/distinfo3
-rw-r--r--devel/py-banal/pkg-descr19
4 files changed, 45 insertions, 0 deletions
diff --git a/devel/Makefile b/devel/Makefile
index 47931a8956cb..0582eaf49010 100644
--- a/devel/Makefile
+++ b/devel/Makefile
@@ -4367,6 +4367,7 @@
SUBDIR += py-backports.tempfile
SUBDIR += py-backports.weakref
SUBDIR += py-backports_abc
+ SUBDIR += py-banal
SUBDIR += py-bandit
SUBDIR += py-bcdoc
SUBDIR += py-bidict
diff --git a/devel/py-banal/Makefile b/devel/py-banal/Makefile
new file mode 100644
index 000000000000..d760228caf9d
--- /dev/null
+++ b/devel/py-banal/Makefile
@@ -0,0 +1,22 @@
+# $FreeBSD$
+
+PORTNAME= banal
+DISTVERSION= 0.3.7
+CATEGORIES= devel python
+MASTER_SITES= CHEESESHOP
+PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER= freebsd_ports@k-worx.org
+COMMENT= Commons of banal micro-functions for Python
+
+LICENSE= MIT
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}six>=0:devel/py-six@${PY_FLAVOR}
+
+USES= python
+USE_PYTHON= distutils autoplist
+
+NO_ARCH= yes
+
+.include <bsd.port.mk>
diff --git a/devel/py-banal/distinfo b/devel/py-banal/distinfo
new file mode 100644
index 000000000000..498451a5f575
--- /dev/null
+++ b/devel/py-banal/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1530200787
+SHA256 (banal-0.3.7.tar.gz) = 1b88caf2e12d96af55cebc5ed8293cdf847ee41c91c3e53e53e895c8b92ddce3
+SIZE (banal-0.3.7.tar.gz) = 3692
diff --git a/devel/py-banal/pkg-descr b/devel/py-banal/pkg-descr
new file mode 100644
index 000000000000..893add4d734f
--- /dev/null
+++ b/devel/py-banal/pkg-descr
@@ -0,0 +1,19 @@
+Commons of Python micro-functions. This is basically an out-sourced, shared
+utils module.
+
+Rules:
+
+- Must work in Python 2 and Python 3
+- Cannot depend on anything but six and the standard library
+
+Functions:
+
+- is_sequence: check if something is list-ish
+- is_mapping: check if an object is dict-ish
+- ensure_list: make sure an argument is a list, or make it into a single-element
+ list
+- clean_dict: remove null values from a dict, recursively
+- decode_path: decode a path name to be unicode
+- hash_data: generate a SHA1 from a dict of reasonable objects
+
+WWW: https://github.com/pudo/banal