What is a good, clean to deal with paths in emacs lisp? Common lisp has pathnames, Python has os.path. But I always seem to end up reinventing the wheel and resorting to manual regexes for simple path operations like getting a path basename, dirname, or joining paths together in a sane way.
What you are, I think, calling "paths" Emacs and Emacs Lisp call "absolute" file or directory names. In Emacs language, a "path" is a list of absolute directory names, as used, for example, in the environment variable
PATH and Emacs variables
exec-path etc. (And yes, Common Lisp refers to these as "paths".)
Beyond that, your question is very general (and risks being closed as too broad). Please consider posing a specific question -- something that you want to do with file names or file-name components. Your question is OK as asking for general info about Emacs file-name functions, but a specific how-to question would also be useful.
elisp has the list
load-path. When you want to add a new path to the scope, just do
(add-to-list 'load-path "my/new/path")
Then, supose you have a file.el in that directory. In the end of the file, put the line
(provide 'file), and then you can require it with:
You can also require files in subfolders of your load-path, if they are provided as such, with