[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
feature/project-switching b7dffcb: Simplify the previous commit
From: |
Simen Heggestøyl |
Subject: |
feature/project-switching b7dffcb: Simplify the previous commit |
Date: |
Wed, 27 May 2020 11:27:09 -0400 (EDT) |
branch: feature/project-switching
commit b7dffcb501d30297e2fa8184b587da18f458ca66
Author: Simen Heggestøyl <address@hidden>
Commit: Simen Heggestøyl <address@hidden>
Simplify the previous commit
* lisp/progmodes/project.el (project--read-project-list): Simplify the
previous commit by utilizing the optional OMIT-NULLS argument to
'split-string'.
---
lisp/progmodes/project.el | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el
index be0b2e4..a3e81d4 100644
--- a/lisp/progmodes/project.el
+++ b/lisp/progmodes/project.el
@@ -732,13 +732,12 @@ loop using the command \\[fileloop-continue]."
(project--ensure-file-exists filename)
(with-temp-buffer
(insert-file-contents filename)
- (let ((dirs (split-string (string-trim (buffer-string)) "\n"))
+ (let ((dirs (split-string (buffer-string) "\n" t))
(project-list '()))
(dolist (dir dirs)
- (unless (string-empty-p dir)
- (cl-pushnew (file-name-as-directory dir)
- project-list
- :test #'equal)))
+ (cl-pushnew (file-name-as-directory dir)
+ project-list
+ :test #'equal))
(setq project--list (reverse project-list))))))
(defun project--ensure-read-project-list ()
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- feature/project-switching b7dffcb: Simplify the previous commit,
Simen Heggestøyl <=