* bug#51365: 29.0.50; org-mode: modification-time error with git controled file
[not found] <878ryjb1y8.fsf@yfb02119.nifty.com>
@ 2021-12-11 16:20 ` Kyle Meyer
0 siblings, 0 replies; only message in thread
From: Kyle Meyer @ 2021-12-11 16:20 UTC (permalink / raw)
To: TAKAHASHI Yoshio; +Cc: 51365
close 51365 28.1
quit
TAKAHASHI Yoshio writes:
> Hi,
>
> With git controled file,
> {{{modification-time(%Y-%02m-%02dT%02H:%02M:%02S+09:00, 1)}}}
> causes "Wrong type argument: stringp, " error.
>
> `org-macro--vc-modified-time' in org-macro.el should pass list of FILE
> to `vc-call', because `vc-git-print-log' expects list of file as its 1st
> argument.
Thanks for the report and fix. This failure is new with Emacs 28,
specifically 3572613550f (Fix vc-git-state for filenames with wildcards,
2021-08-15). Before that, passing a string instead of a list worked
okay because vc-git-print-log just passed its FILES argument untouched
to vc-git-command's FILE-OR-LIST.
> diff --git a/lisp/org/org-macro.el b/lisp/org/org-macro.el
> index b8d3373418..9e70844963 100644
> --- a/lisp/org/org-macro.el
> +++ b/lisp/org/org-macro.el
> @@ -368,7 +368,7 @@ org-macro--vc-modified-time
> date)
> (unwind-protect
> (progn
> - (vc-call print-log file buf nil nil 1)
> + (vc-call print-log (list file) buf nil nil 1)
> (with-current-buffer buf
> (vc-exec-after
> (lambda ()
Looks good to me. I confirmed the bug and fix only with vc-git,
although the change looks appropriate for the other backends too:
$ git grep -E '\(defun vc-.+-print-log'
lisp/vc/vc-bzr.el:(defun vc-bzr-print-log (files buffer &optional shortlog start-revision limit)
lisp/vc/vc-cvs.el:(defun vc-cvs-print-log (files buffer &optional _shortlog _start-revision limit)
lisp/vc/vc-dav.el:(defun vc-dav-print-log (_url)
lisp/vc/vc-git.el:(defun vc-git-print-log (files buffer &optional shortlog start-revision limit)
lisp/vc/vc-hg.el:(defun vc-hg-print-log (files buffer &optional shortlog start-revision limit)
lisp/vc/vc-mtn.el:(defun vc-mtn-print-log (files buffer &optional _shortlog start-revision limit)
lisp/vc/vc-rcs.el:(defun vc-rcs-print-log-cleanup ()
lisp/vc/vc-rcs.el:(defun vc-rcs-print-log (files buffer &optional _shortlog
lisp/vc/vc-sccs.el:(defun vc-sccs-print-log (files buffer &optional _shortlog _start-revision-ignored limit)
lisp/vc/vc-src.el:(defun vc-src-print-log (files buffer &optional shortlog _start-revision limit)
lisp/vc/vc-svn.el:(defun vc-svn-print-log (files buffer &optional _shortlog start-revision limit)
So, I've added a commit message to above patch and applied it in your
name on Org's bugfix branch (888689f2b).
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-12-11 16:22 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <878ryjb1y8.fsf@yfb02119.nifty.com>
2021-12-11 16:20 ` bug#51365: 29.0.50; org-mode: modification-time error with git controled file Kyle Meyer
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).