guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

97/103: gnu: python-flake8: Remove python byte-code files from source.


From: Hartmut Goebel
Subject: 97/103: gnu: python-flake8: Remove python byte-code files from source.
Date: Tue, 25 Oct 2016 17:44:47 +0000 (UTC)

htgoebel pushed a commit to branch wip-python-build-system
in repository guix.

commit 59185ac39fd917f6a619d694cc54cf2354671e1c
Author: Hartmut Goebel <address@hidden>
Date:   Tue Oct 25 18:15:29 2016 +0200

    gnu: python-flake8: Remove python byte-code files from source.
    
    * gnu/packages/python.scm (python-flake8)[source]: Add snippet.
    
    # Conflicts:
    #   gnu/packages/python.scm
---
 gnu/packages/python.scm |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index e738383..99b6f36 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -5197,7 +5197,15 @@ complexity of Python source code.")
         (uri (pypi-uri "flake8" version))
         (sha256
           (base32
-            "0bs9cz4fr99r2rwig1b8jwaadl1nan7kgpdzqwj0bwbckwbmh7nc"))))
+            "0bs9cz4fr99r2rwig1b8jwaadl1nan7kgpdzqwj0bwbckwbmh7nc"))
+        (modules '((guix build utils)))
+        (snippet
+         '(begin
+            ;; Remove pre-compiled .pyc files from source.
+            (for-each delete-file-recursively
+                      (find-files "." "__pycache__" #:directories? #t))
+            (for-each delete-file (find-files "." "\\.pyc$"))
+            #t))))
     (build-system python-build-system)
     (propagated-inputs
       `(("python-pep8" ,python-pep8)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]