branch: externals/setup
commit 4c735174a29f923a20bce15179d3d116d97fd19b
Author: Philip Kaludercic <phil...@posteo.net>
Commit: Philip Kaludercic <phil...@posteo.net>

    Improve :load-form shorthand
    
    The previous version would have issues with load-paths that end with a
    path separator.
---
 setup.el | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/setup.el b/setup.el
index 8840d03..55e12ba 100644
--- a/setup.el
+++ b/setup.el
@@ -521,7 +521,9 @@ the first PACKAGE."
 This macro can be used as HEAD, and it will replace itself with
 the nondirectory part of PATH.
 If PATH does not exist, abort the evaluation."
-  :shorthand (lambda (args) (intern (file-name-nondirectory (cadr args)))))
+  :shorthand (lambda (args) (intern
+                             (file-name-nondirectory
+                              (directory-file-name (cadr args))))))
 
 (setup-define :file-match
   (lambda (pat)

Reply via email to