Is it a namespace trick to prevent future problems?
I noticed a pattern in the Emacs community. When people create some tailor made function and insert it on their init files, they use a convention on the name prefixing it with their initials.
For instance, take a look on this question that I previously asked. The answer is:
(defun ndk/org-clock-sum-current-region (beg end)
(interactive "r")
(let ((s (buffer-substring-no-properties beg end)))
(with-temp-buffer
(insert "* foo\n")
(insert s)
(org-clock-sum)
(message (format "%d" org-clock-file-total-minutes)))))
It was written by the great user NickD. Thus, he used ndk
(k
must come from an unknown last name).
I believe this not an aesthetic effort. At least, not only aesthetic.
This seem to be some sort of "good practice". But I do not see the point. I might be missing something.
Technically, what is the point of doing that? Why not just calling the function org-clock-sum-current-region
? What could you lose doing that?
my-
, since so many people share bits of code.my/
). As @aadcg notes, that's a way to make your code easily shareable. I almost always adapt such code in one way or other to my own style and idioms, and if I do so I always rename with my initials but put a link to the original in a comment, so if I pass my version on the originator still gets their due credit. Creator acknowledgement is the lifeblood of freedom-respecting software.