You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by David Kimdon <dw...@debian.org> on 2003/04/20 23:15:00 UTC
[PATCH] : fix for psvn.el svn-status-mode
Hi,
I received a bug report with a patch in the Debian bug tracking
system[1]. I'm not qualified to evaluate this patch (don't use emacs
or know much lisp). Can anyone evaluate this patch?
Thanks,
David
* tools/client-side/psvn/psvn.el (svn-status-mode) : Make status
buffer read-only directly, instead of going through toggle-read-only
which would enable View mode depending on . Patch thanks to
Kalle Olavi Niemitalo <ko...@iki.fi>.
Index: tools/client-side/psvn/psvn.el
===================================================================
--- tools/client-side/psvn/psvn.el (revision 5680)
+++ tools/client-side/psvn/psvn.el (working copy)
@@ -507,7 +507,7 @@
(setq major-mode 'svn-status-mode)
(setq mode-name "svn-status")
(setq mode-line-process 'svn-status-mode-line-process)
- (toggle-read-only 1))
+ (setq buffer-read-only t))
(defun svn-status-update-mode-line ()
(setq svn-status-mode-line-process
[1] : I have included Kalle's description of the problem and the proposed
solution here. The full bug report can be found at :
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=188706
Kalle's words:
I have enabled view-read-only in Emacs, so that visiting a
read-only file automatically puts it in View mode. Now, when I
use M-x svn-status, the *svn-status* buffer enters View mode too.
Pressing m in the buffer then runs the View mode command
point-to-register, rather than the svn-status mode command
svn-status-set-user-mark.
This is quite easy to fix. At the end of svn-status-mode in
psvn.el, there is the form:
(toggle-read-only 1)
Change it to:
(setq buffer-read-only t)
This way, it makes the buffer read-only directly, instead of
going through toggle-read-only which would enable View mode.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: [PATCH] : fix for psvn.el svn-status-mode
Posted by kf...@collab.net.
David Kimdon <dw...@debian.org> writes:
> I received a bug report with a patch in the Debian bug tracking
> system[1]. I'm not qualified to evaluate this patch (don't use emacs
> or know much lisp). Can anyone evaluate this patch?
Thanks for forwarding the bug report. I committed a slightly
different fix, see revision 5683.
-Karl
> * tools/client-side/psvn/psvn.el (svn-status-mode) : Make status
> buffer read-only directly, instead of going through toggle-read-only
> which would enable View mode depending on . Patch thanks to
> Kalle Olavi Niemitalo <ko...@iki.fi>.
>
> Index: tools/client-side/psvn/psvn.el
> ===================================================================
> --- tools/client-side/psvn/psvn.el (revision 5680)
> +++ tools/client-side/psvn/psvn.el (working copy)
> @@ -507,7 +507,7 @@
> (setq major-mode 'svn-status-mode)
> (setq mode-name "svn-status")
> (setq mode-line-process 'svn-status-mode-line-process)
> - (toggle-read-only 1))
> + (setq buffer-read-only t))
>
> (defun svn-status-update-mode-line ()
> (setq svn-status-mode-line-process
>
>
> [1] : I have included Kalle's description of the problem and the proposed
> solution here. The full bug report can be found at :
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=188706
>
> Kalle's words:
>
> I have enabled view-read-only in Emacs, so that visiting a
> read-only file automatically puts it in View mode. Now, when I
> use M-x svn-status, the *svn-status* buffer enters View mode too.
> Pressing m in the buffer then runs the View mode command
> point-to-register, rather than the svn-status mode command
> svn-status-set-user-mark.
>
> This is quite easy to fix. At the end of svn-status-mode in
> psvn.el, there is the form:
>
> (toggle-read-only 1)
>
> Change it to:
>
> (setq buffer-read-only t)
>
> This way, it makes the buffer read-only directly, instead of
> going through toggle-read-only which would enable View mode.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org