This morning, Matthieu Moy wrote:
> [ Talking about Windows, there's still this in bzr.el which I can't
>   test :
>
>
> (defun bzr-config-directory ()
>   "Path of the configuration directory for bzr."
>   ;; TODO: not windows portable.
>   (expand-file-name "~/.bazaar/"))
>
> (defun bzr-config-file (file)
>   "Path of configuration file FILE for bzr.
>
> File can be, i.e. bazaar.conf, ignore, locations.conf, ..."
>   ;; TODO: not windows portable.
>   (concat (bzr-config-directory) file))
>
>
> If a windows user could provide a patch ... ]

Well, under the documentation on the Bzr site, I found this:

"Location of configuration file

Each user can create a pair of configuration files in $HOME/.bazaar (or
%APPDATA%\bazaar\2.0 on Windows)."

And I have tried to use my ~/ directory, but the docs are right, so I moved my
.bazaar dir to that place. So the following works for me:

(defun bzr-config-directory ()
  "Path of the configuration directory for bzr."
  (if (eq system-type 'windows-nt)
    (expand-file-name  "bazaar/2.0" (getenv "APPDATA"))
    (expand-file-name "~/.bazaar/")))

Now I'm not sure this is the proper way to detect if i'm running on windows,
please use what you've been using for other features!


>
> [EMAIL PROTECTED] (Edgar Gonçalves) writes:
>
>> The features look great, but I started noticing my CPU usage going too often 
>> to
>> the ninety-ish percent.
>
> Did you check that the CPU usage actually comes from Emacs, or is it
> from a subprocess ?
>
> Emacs is mostly non-preemptive, so when it uses the CPU itself, it
> freezes, and you can't use it before it completes (except if the elisp
> code is using some complex tricks, but I'd be surprised if this is the
> case of DVC).
>
> OTOH, we might well be launching subprocesses in an incorrect way.

I just rechecked, the only subprocesses that I can see are gnuserv.exe and
ispell.exe (gnus also launches a cmdproxy.exe to use openssl.exe, but I don't
need to use that to see the cpu abuse). Another interesting fact is that emacs
tries to do whatever it is it's doing in idle time, but only emacs-idle time:
if i'm writing, or moving, or typing in the emacs window, the cpu usage come to
a feasible 5-10 percent. one or two seconds after i click on the desktop, or
another window, emacs fires the turbo mode! Oh, and did I mention that this
turbo mode took my laptop to a burning shutdown a couple of times, already? I
guess the tagline is not meant to be taken literally: "DVC - making your
computer feel HOT!" :)

What do you think about this problem?
>
> -- 
> Matthieu

-- 
Edgar Gonçalves
Software Engineering Group @ INESC-ID
IST/Technical University of Lisbon
Rua Alves Redol, 9, Room 635              
1000-029 Lisboa, Portugal                 
mailto:edgar[DOT]goncalves[AT]inesc[DASH]id[DOT]pt
http://www.esw.inesc-id.pt/~eemg

_______________________________________________
Dvc-dev mailing list
[email protected]
https://mail.gna.org/listinfo/dvc-dev

Reply via email to