From ffea1d47cbbd76fbcd412258f11291320b14be6a Mon Sep 17 00:00:00 2001 From: Liliana Marie Prikler Date: Sat, 6 Aug 2022 09:53:09 +0200 Subject: [PATCH] gnu: ugrep: Simplify snippet. * gnu/packages/search.scm (ugrep)[source]: Use nested for-each loop. Simplify regular expressions. --- gnu/packages/search.scm | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/gnu/packages/search.scm b/gnu/packages/search.scm index 025e862fa4..2d652f5789 100644 --- a/gnu/packages/search.scm +++ b/gnu/packages/search.scm @@ -683,11 +683,13 @@ bibliographic data and simple document and bibtex retrieval.") (base32 "03b3lahc3zzsznaqnrk47f1cnd5jwakvwrkz0r4m2crk09cpfv57")) (file-name (git-file-name name version)) (modules '((guix build utils))) - (snippet #~(begin - (delete-file-recursively "bin") ; pre-built executables - (for-each delete-file (find-files "tests" "^archive\\..*")) - (for-each delete-file (find-files "tests" "^.*\\.pdf$")) - (for-each delete-file (find-files "tests" "^.*\\.class$")))))) + (snippet + #~(begin + (delete-file-recursively "bin") ; pre-built executables + (for-each (lambda (regexp) + (for-each delete-file + (find-files "tests" regexp))) + '("^archive" "\\.pdf$" "\\.class$")))))) (build-system gnu-build-system) (inputs (list bzip2