From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Reuben Thomas Newsgroups: gmane.emacs.devel Subject: Re: desktop.el: autosave? Date: Wed, 10 Apr 2013 11:57:27 +0100 Message-ID: References: <8763zjfe0v.fsf@jurta.org> <87mysridxt.fsf@jurta.org> <20071206153806.GA20731@www.trapp.net> <87d4tjbh0g.fsf@jurta.org> <87abon5q1f.fsf@jurta.org> <87lk835rb7.fsf@jurta.org> <87ejdu6rna.fsf@jurta.org> <87mysi3wx7.fsf@jurta.org> <87k3oaswbl.fsf@mail.jurta.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=089e01160dde1e01ef04d9ff89f8 X-Trace: ger.gmane.org 1365591459 10517 80.91.229.3 (10 Apr 2013 10:57:39 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 10 Apr 2013 10:57:39 +0000 (UTC) Cc: tomas@tuxteam.de, emacs-devel@gnu.org To: Juri Linkov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Apr 10 12:57:41 2013 Return-path: Envelope-to: ged-emacs-devel@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 1UPsii-0004Pp-8S for ged-emacs-devel@m.gmane.org; Wed, 10 Apr 2013 12:57:40 +0200 Original-Received: from localhost ([::1]:37507 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UPsih-00030j-TH for ged-emacs-devel@m.gmane.org; Wed, 10 Apr 2013 06:57:39 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:39546) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UPsiZ-00030S-KK for emacs-devel@gnu.org; Wed, 10 Apr 2013 06:57:36 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UPsiX-0004s0-S0 for emacs-devel@gnu.org; Wed, 10 Apr 2013 06:57:31 -0400 Original-Received: from exprod7og109.obsmtp.com ([64.18.2.171]:54677) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1UPsiX-0004rd-Ja for emacs-devel@gnu.org; Wed, 10 Apr 2013 06:57:29 -0400 Original-Received: from mail-lb0-f197.google.com ([209.85.217.197]) (using TLSv1) by exprod7ob109.postini.com ([64.18.6.12]) with SMTP ID DSNKUWVFl/VlogUYdBoiVna4fda8i6FRkmlO@postini.com; Wed, 10 Apr 2013 03:57:29 PDT Original-Received: by mail-lb0-f197.google.com with SMTP id z13so534768lbh.4 for ; Wed, 10 Apr 2013 03:57:27 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:x-received:in-reply-to:references:date :message-id:subject:from:to:cc:content-type:x-gm-message-state; bh=7uNWxBAftDxDzEoxd+GHA8ZJIq6spRB6HuogwVnmQoc=; b=gXscltDbmhrWn2H/WYY4zGM8OkBd8XJMcZfPkNtE4m2eGTHN8qHP8lZowf0jx5QsAE Ygb3ju7ITccAdd2S+fyKGdCAoQpn/MJy0IZWPbLB5hupYdKh7j7q7Vpnx+pYVkfAt3Bq jluoRU1sPYXv6NBL+MpkK+xH6bwsjhIKfYPq9h64fJ11vchRG8gAgcSZvm8qp27rfOqV jDjKRnRDpyi57tfSJKOiUoihwGMV36QyKhJxfY4/3oXFyK0gPZKj/lWOAA0TSSeIC35w 4IguQww2I/FH+YPZja/iWHIwX9gIH1FKyGjPk7Fi044vTIOB/QuILz5Ea+7FiW+hwFNH do8g== X-Received: by 10.112.162.65 with SMTP id xy1mr915513lbb.105.1365591447303; Wed, 10 Apr 2013 03:57:27 -0700 (PDT) X-Received: by 10.112.162.65 with SMTP id xy1mr915510lbb.105.1365591447163; Wed, 10 Apr 2013 03:57:27 -0700 (PDT) Original-Received: by 10.152.5.40 with HTTP; Wed, 10 Apr 2013 03:57:27 -0700 (PDT) In-Reply-To: <87k3oaswbl.fsf@mail.jurta.org> X-Gm-Message-State: ALoCoQnT/Qtzdgmjy+5ZLZdw74Cj7DYNt2NRQOdGyMgf0NOBiB0AzEERdFZcASBZv4Q4U82DLPRAO2JjEtO3kt36YFBCK96zeQOZKWc2Df0ZAudBZ99r9sJagdgUhemDQNKw9LJLi3/6riSQ4ZtDmeSgp6Wh5VgieA== X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x X-Received-From: 64.18.2.171 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:158819 Archived-At: --089e01160dde1e01ef04d9ff89f8 Content-Type: text/plain; charset=ISO-8859-1 On 10 April 2013 08:05, Juri Linkov wrote: > > I've been happily using essentially the above code (mostly Juri's, with a > > handful of lines by me) since this thread went quiet over five years ago. > > The problem is that the time interval to run auto-save-hook is > not configurable exclusively for desktop mode. If a user wants > to auto-save the desktop less often than to auto-save files > there is no way to do this. > > OTOH, I like the simplicity of the auto-saving feature in savehist > that uses just one option `savehist-autosave-interval' to configure the > interval between autosaves, or nil to disable timer-based auto-saving. > > Savehist uses `run-with-timer'. Why not to do the same in desktop mode? > What are the problems with using `run-with-timer'? > I don't think anyone had a problem with run-with-timer (I just skimmed back through the thread to check), so go ahead and change my patch to use it. -- http://rrt.sc3d.org --089e01160dde1e01ef04d9ff89f8 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
On 10 April 2013 08:05, Juri Linkov <= juri@jurta.org><= /span> wrote:
> I've been happily using essentially the above code (mostly Ju= ri's, with a
> handful of lines by me) since this thread went quiet over five years a= go.

The problem is that the time interval to run auto-save-hook is
not configurable exclusively for desktop mode. =A0If a user wants
to auto-save the desktop less often than to auto-save files
there is no way to do this.

OTOH, I like the simplicity of the auto-saving feature in savehist
that uses just one option `savehist-autosave-interval' to configure the=
interval between autosaves, or nil to disable timer-based auto-saving.

Savehist uses `run-with-timer'. =A0Why not to do the same in desktop mo= de?
What are the problems with using `run-with-timer'?

I don't think a= nyone had a problem with run-with-timer (I just skimmed back through the th= read to check), so go ahead and change my patch to use it.
--089e01160dde1e01ef04d9ff89f8--