From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Sebastien Vauban" Newsgroups: gmane.emacs.help Subject: Calling Ediff which ignores whitespaces from VC Dir Date: Thu, 01 Aug 2013 16:28:38 +0200 Organization: Sebastien Vauban Message-ID: <8661vph4dl.fsf@somewhere.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1375367426 14389 80.91.229.3 (1 Aug 2013 14:30:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 1 Aug 2013 14:30:26 +0000 (UTC) To: help-gnu-emacs-mXXj517/zsQ@public.gmane.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org-mXXj517/zsQ@public.gmane.org Thu Aug 01 16:30:26 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1V4ttV-0004vC-0r for geh-help-gnu-emacs@m.gmane.org; Thu, 01 Aug 2013 16:30:21 +0200 Original-Received: from localhost ([::1]:32825 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V4ttU-0004Qb-LL for geh-help-gnu-emacs@m.gmane.org; Thu, 01 Aug 2013 10:30:20 -0400 Original-Path: usenet.stanford.edu!news.kjsl.com!feeder.erje.net!eu.feeder.erje.net!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 59 Injection-Info: mx05.eternal-september.org; posting-host="402b34550bd938aa98825778083dce0e"; logging-data="15028"; mail-complaints-to="abuse-VVbKFVtnif8H+i2N2EyTrmui9UKz+5OX@public.gmane.org"; posting-account="U2FsdGVkX1+2GcZJd/RkbcHcTVBsyCOX" User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3 (windows-nt) X-Url: Under construction... X-Archive: encrypt Cancel-Lock: sha1:W4XiceOpjv9BvHm9bPPCFdmGxh4= sha1:mtifidrQAqcMmY91rzTXK3/hgBs= Original-Xref: usenet.stanford.edu gnu.emacs.help:200356 X-BeenThere: help-gnu-emacs-mXXj517/zsQ@public.gmane.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org-mXXj517/zsQ@public.gmane.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org-mXXj517/zsQ@public.gmane.org Xref: news.gmane.org gmane.emacs.help:92623 Archived-At: Hello, I'm trying to call my version of `vc-diff' from VC Dir. It simply is a wrapper above `vc-diff' where I enforce the fact that whitespaces must be ignored. I thought this would make it: --8<---------------cut here---------------start------------->8--- ;; hide up-to-date and unregistered files (add-hook 'vc-dir-mode-hook (lambda () (define-key vc-dir-mode-map (kbd "E") 'vc-ediff-ignore-whitespace))) (defun vc-ediff-ignore-whitespace () "Ignore regions that differ in white space & line breaks only." (interactive) (let ((ediff-ignore-similar-regions t)) (vc-ediff))) --8<---------------cut here---------------end--------------->8--- but I always get the error: --8<---------------cut here---------------start------------->8--- Debugger entered--Lisp error: (wrong-number-of-arguments (1 . 2) 0) vc-ediff() (let ((ediff-ignore-similar-regions t)) (vc-ediff)) vc-ediff-ignore-whitespace(nil t) call-interactively(vc-ediff-ignore-whitespace nil nil) --8<---------------cut here---------------end--------------->8--- which I don't really understand. With no certainty, I've tried to copy the parameters of `vc-ediff': --8<---------------cut here---------------start------------->8--- (defun vc-ediff-ignore-whitespace (historic &optional not-urgent) "Ignore regions that differ in white space & line breaks only." (interactive (list current-prefix-arg t)) (let ((ediff-ignore-similar-regions t)) (vc-ediff historic not-urgent))) --8<---------------cut here---------------end--------------->8--- then it worked further... Though, I now have: call-interactively: Symbol's value as variable is void: ediff-ignore-similar-regions when pressing `n' to go to the first difference region. Any help? Best regards, Seb -- Sebastien Vauban