FUEL: Flip the default behavior of visit-other-file so that it does not try to create -docs or -tests files if they do not exist by default. This is the more common case when spelunking in code and in general you want to scaffold those files anyway.
parent
536ae3c648
commit
bb3665f37e
|
@ -245,11 +245,11 @@ code in the buffer."
|
|||
(defsubst factor-mode--in-tests (&optional file)
|
||||
(factor-mode--code-file "tests"))
|
||||
|
||||
(defun factor-mode-visit-other-file (&optional skip)
|
||||
(defun factor-mode-visit-other-file (&optional create)
|
||||
"Cycle between code, tests and docs factor files.
|
||||
With prefix, non-existing files will be skipped."
|
||||
With prefix, non-existing files will be created."
|
||||
(interactive "P")
|
||||
(let ((file (factor-mode--cycle-next (buffer-file-name) skip)))
|
||||
(let ((file (factor-mode--cycle-next (buffer-file-name) (not create))))
|
||||
(unless file (error "No other file found"))
|
||||
(find-file file)
|
||||
(unless (file-exists-p file)
|
||||
|
|
Loading…
Reference in New Issue