me
/
guix
Archived
1
0
Fork 0

import/cran: Fix detection of Fortran files.

This fixes a bug whereby the Guix importer considers files like .f.* to be
Fortran files.

The expression "\\.f(90|95)?" would match a lot of files containing ".f"
although they are not Fortran files.  Instead we should only consider files
with this *suffix*.

* guix/import/cran.scm (directory-needs-fortran?): Only check for suffixes.

Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
master
Mădălin Ionel Patrașcu 2021-02-23 12:00:21 +01:00 committed by Ricardo Wurmus
parent 747f68bfb2
commit 35814292b6
No known key found for this signature in database
GPG Key ID: 197A5888235FACAC
1 changed files with 1 additions and 1 deletions

View File

@ -361,7 +361,7 @@ empty list when the FIELD cannot be found."
(define (directory-needs-fortran? dir) (define (directory-needs-fortran? dir)
"Check if the directory DIR contains Fortran source files." "Check if the directory DIR contains Fortran source files."
(match (find-files dir "\\.f(90|95)?") (match (find-files dir "\\.f(90|95)$")
(() #f) (() #f)
(_ #t))) (_ #t)))