Comment 6 for bug 391334

Revision history for this message
Alexander Belchenko (bialix) wrote : Re: [Bug 391334] Re: Bazaar > Explore > System Log doesnt work

David Roberts пишет:
> Does the following observation help...
>
> If I go to a console (Command Prompt) window and enter -
>
> C:\<path_to>WORDPAD.EXE <path_to>.bzr.log
>
> I get an error box from WordPad that says
> "The document <path_to>BZR~1.LOG is in use by another application and cannot be accessed."
>
> Might it be that underlying error that is being passed back to the BE
> app?

Maybe, but only if you're using wordpad as your default editor for bzr.
You can specify any other editor using bzr qconfig command (or in bzr-explorer run Settings ->
Configuration -> User Configuration).

But then problem occurs if your editor of choice has spaces in the path (so you need to quote the
path) and *all* backslashes in path sould be converted to slashes (e.g. instead of "C:\Program
Files\Notepad++\notepad++.exe" you have to use "C:/Program Files/Notepad++/notepad++.exe").

> My hunch is that by default WordPad wants to open the file in RW mode,
> and that the process running BzrExplorer already has the file open in W
> mode, so the request fails? A quick web search has failed to find a
> ReadOnly command line switch for WordPad. Can we choose another file
> viewer for looking at the log file - bzr qviewer seems to work ok on
> .bzr.log when invoked from the command line.

+1 for using qviewer for this. It helps avoiding many windows-specific problems with %(EDITOR)s.

Ian, do you agree for this change? E.g.:

=== modified file lib/app_suite.py
--- lib/app_suite.py 2009-08-19 05:43:44 +0000
+++ lib/app_suite.py 2009-08-23 18:14:49 +0000
@@ -164,7 +164,7 @@
     "plugins": "bzr qplugins",
     "version": "bzr qversion",
     "config:bazaar.conf": "bzr qconfig",
- ".bzr.log": '%(EDITOR)s "%(BZR_LOG)s"',
+ ".bzr.log": 'bzr qviewer "%(BZR_LOG)s"',
     }
 _QBZR_LOCAL_MAPPING = {
     "add": "bzr qadd --ui-mode %(selected)s",