This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun js-jump-to (current from to format-name) | |
(find-file | |
(cl-loop with parts = (reverse current) | |
with fname = (file-name-sans-extension (cl-first parts)) | |
for (name . rest) on (cl-rest parts) | |
until (string-equal name from) | |
collect name into names | |
finally (cl-return | |
(mapconcat 'identity | |
(nconc (reverse rest) |