aboutsummaryrefslogtreecommitdiff
path: root/battering/packages
diff options
context:
space:
mode:
Diffstat (limited to 'battering/packages')
-rw-r--r--battering/packages/python-xyz.scm31
1 files changed, 31 insertions, 0 deletions
diff --git a/battering/packages/python-xyz.scm b/battering/packages/python-xyz.scm
index 547d354..c7bd357 100644
--- a/battering/packages/python-xyz.scm
+++ b/battering/packages/python-xyz.scm
@@ -362,3 +362,34 @@ declarative configuration.")
(description
"Streamlined Cython bindings for the harfbuzz shaping engine.")
(license license:asl2.0)))
+
+(define-public python-untokenize
+ (package
+ (name "python-untokenize")
+ (version "0.1.1")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/myint/untokenize")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "10rklx9ly1zmnlh29i1jps62dd05dd05cnv7sa3lqaqy8h13idc8"))))
+ (build-system pyproject-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (replace 'check
+ (lambda _
+ (invoke "python" "./test_untokenize.py")
+ (invoke "python" "./test_acid.py"))))))
+ (native-inputs (list python-setuptools python-wheel))
+ (home-page "https://github.com/myint/untokenize")
+ (synopsis
+ "Transforms tokens into original source code (while preserving whitespace).")
+ (description
+ "This package transforms tokens into source code. Unlike the standard
+library's @code{tokenize.untokenize()}, it preserves the original whitespace
+between tokens.")
+ (license license:expat)))