Open related file reddit / emacs ---------------------------------------------------------------------- bespokey · 2022-12-09 21:23 How can I open a file related to the currently-visited buffer file, and have it customized using functions? For example: open a C header file when visiting a *.c file, or open the Ansible defaults/main.yml file when visiting a tasks/main.yml file of an Ansible role. ---------------------------------------------------------------------- mickeyp · 2022-12-09 21:30 Try `ff-find-related-file` and look at `ff-other-file-alist` if you want to customize how the relationships are handled. (There's also `ffap` for opening related files at point) ---------------------------------------------------------------------- bespokey · 2022-12-09 22:41 Thanks! ---------------------------------------------------------------------- github-alphapapa · 2022-12-10 14:36 Also, `C-x p f` may be helpful. ---------------------------------------------------------------------- bespokey · 2022-12-10 16:08 That, or projectile which I currently use, or simply navigating with completing-read find-file. The idea is to have related files without typing their names as that gets cumbersome depending on the project size.