diff mbox

[v2,3/7] gnu: python-zope-testing: Strip byte-code and backup-files from source.

Message ID 1476351811-31727-4-git-send-email-h.goebel@crazy-compilers.com
State New
Headers show

Commit Message

Hartmut Goebel Oct. 13, 2016, 9:43 a.m. UTC
* gnu/package/python.scm (python-zope-testing, python2-zope-testing)[source]:
  Add snippet to strip byte-code and backup-files.
---
 gnu/packages/python.scm | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index eca60bc..ec56c85 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -6644,7 +6644,13 @@  that have uses outside of the Zope framework.")
                            "/zope.testing/zope.testing-" version ".tar.gz"))
        (sha256
         (base32
-         "1yvglxhzvhl45mndvn9gskx2ph30zz1bz7rrlyfs62fv2pvih90s"))))
+         "1yvglxhzvhl45mndvn9gskx2ph30zz1bz7rrlyfs62fv2pvih90s"))
+       (modules '((guix build utils)))
+       (snippet
+        '(begin
+           ;; Remove pre-compiled .pyc files backup files from source.
+           (for-each delete-file (find-files "." "(\\.pyc|~)$"))
+           #t))))
     (build-system python-build-system)
     (native-inputs
      `(("python-zope-exceptions" ,python-zope-exceptions)))