diff options
author | Maxim Cournoyer <maxim.cournoyer@gmail.com> | 2021-12-20 12:42:03 -0500 |
---|---|---|
committer | Maxim Cournoyer <maxim.cournoyer@gmail.com> | 2022-01-10 11:44:41 -0500 |
commit | 84558f252ebb9f79c8deef8a0aa52b41e3c6f664 (patch) | |
tree | b827620c6814a14d9a1691c4262f69038f89e12a | |
parent | ded3b554f9c3a05424e0dfa46a751347a1f3c2a9 (diff) | |
download | guix-84558f252ebb9f79c8deef8a0aa52b41e3c6f664.tar guix-84558f252ebb9f79c8deef8a0aa52b41e3c6f664.tar.gz |
gnu: Add python-tomli-w.
* gnu/packages/python-build.scm (python-tomli-w): New variable.
-rw-r--r-- | gnu/packages/python-build.scm | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/gnu/packages/python-build.scm b/gnu/packages/python-build.scm index a972a752be..2abb781f76 100644 --- a/gnu/packages/python-build.scm +++ b/gnu/packages/python-build.scm @@ -26,6 +26,7 @@ #:use-module (gnu packages) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build-system python) + #:use-module (guix gexp) #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix packages)) @@ -92,6 +93,38 @@ installed with a newer @code{pip} or with wheel's own command line utility.") Language (TOML) configuration files.") (license license:expat))) +(define-public python-tomli-w + (package + (name "python-tomli-w") + (version "1.0.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "tomli_w" version)) + (sha256 + (base32 "1fg13bfq5qy1ym4x77815nhxh1xpfs0drhn9r9464cz00m1l6qzl")))) + (build-system python-build-system) + (arguments + (list + #:tests? #f ;to avoid extra dependencies + #:phases + #~(modify-phases %standard-phases + ;; XXX: PEP 517 manual build copied from python-isort. + (replace 'build + (lambda _ + (invoke "python" "-m" "build" "--wheel" "--no-isolation" "."))) + (replace 'install + (lambda _ + (let ((whl (car (find-files "dist" "\\.whl$")))) + (invoke "pip" "--no-cache-dir" "--no-input" + "install" "--no-deps" "--prefix" #$output whl))))))) + (native-inputs (list python-pypa-build python-flit-core)) + (home-page "https://github.com/hukkin/tomli-w") + (synopsis "Minimal TOML writer") + (description "Tomli-W is a Python library for writing TOML. It is a +write-only counterpart to Tomli, which is a read-only TOML parser.") + (license license:expat))) + (define-public python-pytoml (package (name "python-pytoml") |