[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/relint 5572c57 14/16: Emacs 26 compatibility: `director
From: |
Mattias Engdeg�rd |
Subject: |
[elpa] externals/relint 5572c57 14/16: Emacs 26 compatibility: `directory-files-recursively` |
Date: |
Mon, 30 Nov 2020 05:01:00 -0500 (EST) |
branch: externals/relint
commit 5572c5770ceba5b3aff3864a49985cadd32e71d4
Author: Mattias Engdegård <mattiase@acm.org>
Commit: Mattias Engdegård <mattiase@acm.org>
Emacs 26 compatibility: `directory-files-recursively`
The PREDICATE argument to `directory-files-recursively` was added in
Emacs 27.1; use it conditionally.
---
relint.el | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/relint.el b/relint.el
index 81d46be..10f5d74 100644
--- a/relint.el
+++ b/relint.el
@@ -2391,10 +2391,13 @@ TARGET is the file or directory to use for a repeated
run."
(cons total-errors total-suppressed)))
(defun relint--tree-files (dir)
- (directory-files-recursively
- dir (rx bos (not (any ".")) (* anything) ".el" eos) nil
- ;; Save time by not pointlessly descending into huge .git directories.
- (lambda (s) (not (string-suffix-p "/.git" s)))))
+ (let ((re (rx bos (not (any ".")) (* anything) ".el" eos)))
+ (if (>= emacs-major-version 27)
+ (directory-files-recursively
+ dir re nil
+ ;; Save time by not pointlessly descending into huge .git directories.
+ (lambda (s) (not (string-suffix-p "/.git" s))))
+ (directory-files-recursively dir re))))
(defun relint--scan-buffer (buffer)
"Scan BUFFER; return (COMPLAINTS . SUPPRESSED) where
- [elpa] externals/relint d0fa8a8 10/16: Fix false positives in regexp provenance checks, (continued)
- [elpa] externals/relint d0fa8a8 10/16: Fix false positives in regexp provenance checks, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint 29e5427 11/16: Recognise a few more `featurep` arguments, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint 26639c5 16/16: Require xr 1.20, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint 7690e3a 08/16: Scan font-lock-defaults correctly, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint 4b78e14 09/16: Add table of contents to README, and some advice, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint c792bde 15/16: Perform Emacs version check at compile time, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint c8fd922 12/16: Minor looking-at optimisation, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint 5720e12 07/16: Scan regexp arguments to functions in s.el, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint f0241bc 13/16: Increment version to 1.19, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint 9173a91 05/16: Add progress indicator for interactive relint-directory, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint 5572c57 14/16: Emacs 26 compatibility: `directory-files-recursively`,
Mattias Engdeg�rd <=
- [elpa] externals/relint 1c66438 06/16: Add string-search and string-replace to the list of pure functions, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint b572fcd 02/16: Run automatic tests on Emacs 27.1, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint 14a5135 03/16: Minor README correction, Mattias Engdeg�rd, 2020/11/30
- [elpa] externals/relint 8ee9f79 04/16: Avoid descending into .git/ when looking for .el files, Mattias Engdeg�rd, 2020/11/30