From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id iKnHLv4lv182fQAA0tVLHw (envelope-from ) for ; Thu, 26 Nov 2020 03:50:22 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id wJCxKv4lv18gPQAAB5/wlQ (envelope-from ) for ; Thu, 26 Nov 2020 03:50:22 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 04F3694011C for ; Thu, 26 Nov 2020 03:50:22 +0000 (UTC) Received: from localhost ([::1]:60234 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ki8IW-0005g1-23 for larch@yhetil.org; Wed, 25 Nov 2020 22:50:20 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:56034) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ki8HO-0005ez-JP for emacs-orgmode@gnu.org; Wed, 25 Nov 2020 22:49:10 -0500 Received: from mail-pg1-x535.google.com ([2607:f8b0:4864:20::535]:38985) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ki8HD-0002Xf-VI for emacs-orgmode@gnu.org; Wed, 25 Nov 2020 22:49:05 -0500 Received: by mail-pg1-x535.google.com with SMTP id f17so559105pge.6 for ; Wed, 25 Nov 2020 19:48:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-transfer-encoding; bh=0n06by4oHAvLWfAU0E90E+dGvlvLmxfKinWhzTk52e0=; b=Rzri+ZAEIV5+J8X1l9Phf4Guk5RsueMM7f/JeG+ytHM5qcxYgQLnDrIbE6zO9uOZtc pz+b4JfgbQb+7e9ENFB6slbjfDRcutIZihLkJdWMnIdDLYNrZ7smHQwnAaF9WtNYwt7Q BItsaP72rjItRpt3WlJqtQszGwtOtLhq+Pvi2E/amIzlXpEKjsXyoDCJjqbkYiSnVPtG oYo7KZ4ux8XeAjT1QNICSmAc2H+a8J67reB/tkqRiLbvZ70oMw7vbwPC1WJnm+bFA6ar ntYdtsL0Yv/Ml0y1HFlGbLS2iK7NUlJRtBRBt2/aYwtD+CbymuFNRWUZdvMTvFvWgyw/ DCqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version:content-transfer-encoding; bh=0n06by4oHAvLWfAU0E90E+dGvlvLmxfKinWhzTk52e0=; b=Tw2FOdkbVcxFsCyZFyWrFzgWv33KYue48TMw3MHlx37aPPW7xqCETrrUUpwDQZUgxw WvaP0Llx1ULptFZju3CQuc2opqpplSF79kjfF2IiihNyIvuS4DguLO9AbxANXwOvNW8C 6WmS01M4TSplj7VjaqFjP9SvxMqMq6IsC6YO6WnVpORoC0zgvKjXkdUTrwjfZzNyKCj2 nFj+hPvoy6So0B4+i8pMKDTM1ojiohi8rmgHriVJeW7JKPh1OL0+SRP21EsPU2ZSbrlu nWc0+F09ddYVJQSTxwZHDGEsQTl5NXkT5dtdbLaB8ATg5uu/8UjJ9yGteyJ8IYpY7XMv hPNQ== X-Gm-Message-State: AOAM5328MKH5mutgA6ywEIS3dxuvtvakzonpVb09ekLpUyZcMWFMjjuh oWnErTXWHtkmpchAjdFGvVo= X-Google-Smtp-Source: ABdhPJz0P7hiT8MSc19Qd61vOWu40QhhShZkuhZJWp+54Up5KOT5NWT6LyUtIJvdTq4xAVvh9QV9UQ== X-Received: by 2002:a17:90a:b782:: with SMTP id m2mr1213774pjr.185.1606362538336; Wed, 25 Nov 2020 19:48:58 -0800 (PST) Received: from localhost ([104.250.131.79]) by smtp.gmail.com with ESMTPSA id d19sm4205646pjs.0.2020.11.25.19.48.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Nov 2020 19:48:57 -0800 (PST) From: Ihor Radchenko To: "Dr. Arne Babenhauserheide" , Jean Louis Subject: Re: One vs many directories In-Reply-To: <87360yegmg.fsf@web.de> References: <87mtz84om9.fsf@localhost> <87360yegmg.fsf@web.de> Date: Thu, 26 Nov 2020 11:47:53 +0800 Message-ID: <871rggbwye.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2607:f8b0:4864:20::535; envelope-from=yantar92@gmail.com; helo=mail-pg1-x535.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Texas Cyberthal , emacs-orgmode@gnu.org Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: inc X-Scanner: ns3122888.ip-94-23-21.eu Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b=Rzri+ZAE; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Spam-Score: 0.29 X-TUID: jhnk+n1mEBaP > For my own setup I run code in a hook to update the agenda whenever I > change a TODO state, clock in or clock out, but that has performance > problems when I do it while the Agenda is shown. You do not have or update the whole agenda view. I use the following code to update the clocking highlights in agenda even when I clock-in/out outside the agenda buffer: https://github.com/yantar92/emacs-config/blob/master/config.org#update-high= light-from-currently-clocked-task-in-agenda-even-if-the-task-was-clocked-in= out-from-outside The same can be done for todo state changes using org-agenda-change-all-lines Best, Ihor "Dr. Arne Babenhauserheide" writes: > Jean Louis writes: > >> Some people maybe access multiple Org files through Agenda, me I >> don't. Some items are "non existent" and I do not know how to ask >> agenda to refresh itself. > > Simply press the letter g. > > For my own setup I run code in a hook to update the agenda whenever I > change a TODO state, clock in or clock out, but that has performance > problems when I do it while the Agenda is shown. > > (defvar todo-modified-from-agenda nil "Indicates whether org-mode tod= o state changes were triggered from the agenda. Check this to avoid trying = to propagate the change back into the agenda") > ;; continuously update agenda view, from http://thomasf.github.io/sol= arized-css/test/org-hacks.html > (defun kiwon/org-agenda-redo-in-other-window () > "Call org-agenda-redo function even in the non-agenda buffer." > (interactive) > (when (not (and (boundp 'todo-modified-from-agenda) todo-modified-f= rom-agenda)) ; org-state non-nil means we=E2=80=99re coming from the org-af= ter-todo-state-change-hook, which would throw when changing todo states fro= m agenda due to a circular action > (let ((agenda-window (get-buffer-window (or (and (boundp 'org-age= nda-buffer-name) org-agenda-buffer-name) "plan.org") t))) > (when agenda-window > (with-selected-window agenda-window > (org-agenda-redo)))))) > ;; advice agenda todo to avoid redo, thanks to http://nullprogram.com= /blog/2013/01/22/ > (defadvice org-agenda-todo (before org-agenda-disable-redo activate) > (setq todo-modified-from-agenda t)) > (defadvice org-agenda-todo (after org-agenda-enable-redo activate) > (setq todo-modified-from-agenda nil)) >=20=20=20=20=20 > (add-hook 'org-clock-in-hook 'kiwon/org-agenda-redo-in-other-window) > (add-hook 'org-clock-out-hook 'kiwon/org-agenda-redo-in-other-window) > (add-hook 'org-after-todo-state-change-hook 'kiwon/org-agenda-redo-in= -other-window) > > > Best wishes, > Arne > --=20 > Unpolitisch sein > hei=C3=9Ft politisch sein > ohne es zu merken