From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id GFv5AQVzPmC3fgAA0tVLHw (envelope-from ) for ; Tue, 02 Mar 2021 17:16:53 +0000 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id SPuHOQRzPmCxBwAA1q6Kng (envelope-from ) for ; Tue, 02 Mar 2021 17:16:52 +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 440AF2E50D for ; Tue, 2 Mar 2021 18:16:52 +0100 (CET) Received: from localhost ([::1]:36494 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lH8dd-0004W7-O2 for larch@yhetil.org; Tue, 02 Mar 2021 12:16:49 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:48232) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lH8c9-0004UZ-0l for emacs-orgmode@gnu.org; Tue, 02 Mar 2021 12:15:17 -0500 Received: from ciao.gmane.io ([116.202.254.214]:45666) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lH8c7-0000hY-Fc for emacs-orgmode@gnu.org; Tue, 02 Mar 2021 12:15:16 -0500 Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1lH8c4-0000JE-0Z for emacs-orgmode@gnu.org; Tue, 02 Mar 2021 18:15:12 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: emacs-orgmode@gnu.org From: Maxim Nikulin Subject: org-refile-use-cache and jumps using org-refile or org-goto Date: Wed, 3 Mar 2021 00:15:06 +0700 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 X-Mozilla-News-Host: news://news.gmane.io:119 Content-Language: en-US Received-SPF: pass client-ip=116.202.254.214; envelope-from=geo-emacs-orgmode@m.gmane-mx.org; helo=ciao.gmane.io X-Spam_score_int: 28 X-Spam_score: 2.8 X-Spam_bar: ++ X-Spam_report: (2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_ADSP_CUSTOM_MED=0.001, FORGED_GMAIL_RCVD=1, FORGED_MUA_MOZILLA=2.309, FREEMAIL_FORGED_FROMDOMAIN=0.25, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25, NML_ADSP_CUSTOM_MED=0.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no 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: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1614705412; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=NCvX3ZbzCS+5m85GM/PKBv4vzhDymfpytKoObbE6nRE=; b=LCEzjTHfD7EjgOtm6L9kBNWbGknKRe0pb8M5K8SnssJTQBClJobYIiAOBlDQVl8+JyUiX5 qGT57a66hfulFHlmyq4uvO/wiMUqoPXK+S938HoVUw/grNFll9l8x7F9ZBIzzRi8zOe9he QloKcVtvWu7/k7BtGeqhzdPZTLN4ABfOJmMOJ9+fytKF99cF35TWNskKoe9Jf72zRGJmZU CPydedlUcMtXvjap5ftbPluMwiu44yt2hPLlivnfbcmigYnAf8N6k8icy25GhtuQu4aUt9 0PJwnvltBtq8UHxOTxKmyMZXTRS4FJagsE9Aw5Z5UjikaJyhnjWYn/CEl9/v1w== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1614705412; a=rsa-sha256; cv=none; b=XHTZ+wIyRPCeZTtcy9TBQOqCsZioOs4MVlP/ShH3arbatTQb58Ar7fFxg+aQedvw2LUB6v 16H4+zgr0jNvnsMXYrl8jQFnbNqkb++zaXWlKeM7ADZ/EQdC3kzx8a5aSpPzqpb2FCUoFa ztOAvrQMKqQY288qlztpnJtAiyhF0vMbQNybpN84IqCmAfDdTSxNZPWqIGX8x0eu906XHS 2ON3I7gqV0/bseAsVhbC343Bg2EQewUnRdkLuU+GsWYIiYDOg9MySKUZuUXFFJoYU+QB8K fq8sIypq3ieUjmukxphBZqkkF7YL0WyKOy32p0pOIV1uSnX5zivHSTFVyLpalw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=gmail.com (policy=none); 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-Migadu-Spam-Score: -1.76 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=gmail.com (policy=none); 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-Migadu-Queue-Id: 440AF2E50D X-Spam-Score: -1.76 X-Migadu-Scanner: scn1.migadu.com X-TUID: 3nWk7VM41tXI It seems, something goes a bit wrong. However it is rather confusion than anything really broken. Maybe everybody uses helm, ivy, etc., so nobody is affected. Usually I jump from one note to another heading with C-u C-c C-j (org-goto interface with target completion). I have not setup helm or other similar package. Completion works, maybe it is not really perfect (e.g. completion of top-level headings and deeper ones differ a bit). I have heard that C-u C-c C-w (org-refile) could work in a similar way. I did not like the latter variant due to mandatory file name in the beginning of a target. I have tried to enable org-refile-use-cache. Now completion options depends on what method was called earlier: org-refile or org-goto. If after cache clean up (C-u C-u C-u C-c C-w) first command was C-u C-c C-j (org-goto) than there is no file name as a prefix for both commands. However file name is prepended for both C-u C-c C-j and C-u C-c C-w if at first org-refile was called. There is one issue however. Default option option does not work if after cache clean other command is called, e.g. - jump using C-u C-c C-j - clean cache C-u C-u C-u C-c C-w - try to jump or to refile [C-u] C-c C-w to default offered option - "user-error: Invalid target location" I have just one file in the org-agenda-files list. It is becoming larger, that is why I decided to try org-refile-use-cache. My customization is minimal (besides org-default-dir and org-agenda-files): (org-refile-targets (quote ((org-agenda-files :maxlevel . 5)))) (org-outline-path-complete-in-steps nil) I have tried to add (nil :maxlevel . 5) to org-refile-targets to check if options without file name will appear in addition to ones with file name for org-refile, but it has not happened. It was not clear at first that it is possible to start query with "/" and file name is added when TAB is pressed. Is it expected that with cache enabled, command that causes cache update affects appearance of completion options to its sibling (org-refile and org-goto)?