0
0
Fork 1
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-09-29 21:07:54 +00:00

org-git-link.el: Fix `org-git-find-gitdir'

* contrib/lisp/org-git-link.el (org-git-find-gitdir): Expand
abbreviated directory name.

TINYCHANGE
This commit is contained in:
Chunyang Xu 2017-05-29 17:03:24 +08:00 committed by Kyle Meyer
parent 1afcf2c9aa
commit 1fbbce4d81

View file

@ -126,7 +126,7 @@
the path. Example: (org-git-find-gitdir
\"~/gitrepos/foo/bar.txt\") returns
'(\"/home/user/gitrepos/.git\" \"foo/bar.txt\"). When not in a git repository, return nil."
(let ((dir (file-name-directory path))
(let ((dir (expand-file-name (file-name-directory path)))
(relpath (file-name-nondirectory path)))
(catch 'toplevel
(while (not (file-exists-p (expand-file-name ".git" dir)))