summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHartmut Goebel <h.goebel@crazy-compilers.com>2016-10-13 11:11:42 +0200
committerHartmut Goebel <h.goebel@crazy-compilers.com>2016-10-20 10:09:59 +0200
commitb7703c8131f377a6286c3f888e7d865ad2c230b8 (patch)
tree8f6374053de4c2871ed6c59dcf8a3cbf9c373ac4
parent8ab59181a423542c34170e049e06f1a1377eb202 (diff)
downloadpatches-b7703c8131f377a6286c3f888e7d865ad2c230b8.tar
patches-b7703c8131f377a6286c3f888e7d865ad2c230b8.tar.gz
gnu: Add python2-pathlib2.
Adding only the Python 2 variant, since for Python 3 our minimum version is 3.4 which already includes this package as part of the standard library. gnu/packages/python.scm (python2-pathlib2): New variable.
-rw-r--r--gnu/packages/python.scm36
1 files changed, 36 insertions, 0 deletions
diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 268dd513e3..ca109faf69 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -8887,6 +8887,42 @@ anymore.")
(define-public python2-pathlib
(package-with-python2 python-pathlib))
+(define-public python2-pathlib2
+ (package
+ (name "python2-pathlib2")
+ (version "2.1.0")
+ (source (origin
+ (method url-fetch)
+ (uri (pypi-uri "pathlib2" version))
+ (sha256
+ (base32
+ "0p050msg5c8d0kadv702jnfshaxrb0il765cpkgnhn6mq5hakcyy"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:python ,python-2))
+ (native-inputs
+ `(("python2-setuptools" ,python2-setuptools)
+ ("python2-six" ,python2-six)))
+ (home-page "http://pypi.python.org/pypi/pathlib2/")
+ (synopsis "Object-oriented file system paths - backport of standard
+pathlib module")
+ (description "The goal of pathlib2 is to provide a backport of standard
+pathlib module which tracks the standard library module, so all the newest
+features of the standard pathlib can be used also on older Python versions.
+
+Pathlib offers a set of classes to handle file system paths. It offers the
+following advantages over using string objects:
+
+@enumerate
+@item No more cumbersome use of os and os.path functions. Everything can
+be done easily through operators, attribute accesses, and method calls.
+@item Embodies the semantics of different path types. For example,
+comparing Windows paths ignores casing.
+@item Well-defined semantics, eliminating any inconsistencies or
+ambiguities (forward vs. backward slashes, etc.).
+@end enumerate")
+ (license license:expat)))
+
(define-public python-jellyfish
(package
(name "python-jellyfish")