rocky / emacs-load-relative

Relative loads for Emacs Lisp files. Adds functions __FILE__ and load-relative and require-relative.

This URL has Read+Write access

commit  ab11fd5853b25f49e677e5f007ad9e36fc7d0e03
tree    63a6d386e8569104bf77f8a6d44688e975272e37
parent  75cbd6499d3f85d38e210b1f4c5fe231cb99ce51
README
Here we add two functions load-relative and __FILE__

load-relative(symbol) loads an Emacs Lisp file relative to another
(presumably currently running) Emacs Lisp file.

Example:

(provide 'foo-bar)
(load-relative "baz" 'foo-bar)

__FILE__(symbol) returns the file that symbol was defined it, however
if you are currently running load, that file name is given instead.
If symbol is not defined and you are not loading a file, then nil is
returned.

The symbol parameter is an artifact in both load-relative and __FILE__
that I would like to remove. Right now I don't see how to.