Thierry Volpiatto <[email protected]> writes:
> Victor Rodriguez <[email protected]> writes:
>
>> Hello,
>>
>> I think I have a problem using the mercurial integration. After
>> running dvc-status, using 'l' or 'L' brings up the log for the tree,
>> except that it brings up *all* the log. This is a problem since I
>> have a repository with a lot of history.
>>
>> I found out that if I run xhg-log directly, for example using (xhg-log
>> -5), then hg log will be run with the "-l 5" parameter, displaying
>> only 5 log entries, which is exactly what I need. The problem is that
>> I cannot figure out how to pass this parameter to xhg-log, or to set
>> it up permanently. Setting the value of dvc-log-last-n does not have
>> any effect.
In dvc-status mode, L runs dvc-log, which is declared as:
(defun dvc-log (&optional path last-n)
"Display the brief log for PATH (a file-name; default current
buffer file name; nil means entire tree; prefix arg means prompt
for tree), LAST-N entries (default `dvc-log-last-n'; all if
nil). Use `dvc-changelog' for the full log."
(interactive (list (if current-prefix-arg nil (buffer-file-name))
dvc-log-last-n))
'last-n' should always default to dvc-log-last-n.
Are you familiar with running lisp code in the interactive debugger?
Open dvc-unified.el, put point anywhere in the definition of dvc-log,
and type C-M-x; that "instruments dvc-log for debugging". Then invoke
it as you normally do; it will single step thru the function. Use
<space> to step, e to evaluate a symbol; examine last-n at the
invocation of dvc-call "dvc-log".
If that's ok, the next step is to debug xhg-dvc-log, defined in
xhg-revision.el as:
(defun xhg-dvc-log (path last-n)
"Show a dvc formatted log for xhg."
(interactive (list default-directory nil))
this always defaults last-n to nil when run directly, but that should
not matter when it is called from dvc-log.
> Use C-u -5 M-x xhg-log
This should work.
> (or C-x V l) ;-)
This runs dvc-changelog, which provides no mechanism to set last-n, so
that won't work either.
I don't have xhg installed, so I can't effectively debug this.
>> I'll appreciate any help. At work, Emacs is losing the battle against
>> tortoise-hg! :-P
That's sad.
--
-- Stephe
_______________________________________________
Dvc-dev mailing list
[email protected]
https://mail.gna.org/listinfo/dvc-dev