From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kyle Meyer Subject: Re: Bug: Org loses data if the user types C-u C-c C-c while composing a state change note [9.0.9 (9.0.9-elpaplus @ /home/jorge/.emacs.d/elpa/org-plus-contrib-20170622/)] Date: Sat, 01 Jul 2017 15:19:08 -0400 Message-ID: <87bmp4vuc3.fsf@kyleam.com> References: <87vaniv6dd.fsf@nicolasgoaziou.fr> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45704) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dRNvK-0004w8-Ae for emacs-orgmode@gnu.org; Sat, 01 Jul 2017 15:19:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dRNvG-0001Xz-CG for emacs-orgmode@gnu.org; Sat, 01 Jul 2017 15:19:18 -0400 Received: from pb-smtp1.pobox.com ([64.147.108.70]:55049 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dRNvG-0001X2-2z for emacs-orgmode@gnu.org; Sat, 01 Jul 2017 15:19:14 -0400 In-Reply-To: <87vaniv6dd.fsf@nicolasgoaziou.fr> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Nicolas Goaziou , Jorge Morais Neto Cc: org mode Nicolas Goaziou writes: [...] > FWIW, long ago, I added > > (defun ngz-org-capture-hook-handler () > (define-key org-capture-mode-map "\C-x\C-s" 'org-capture-finalize) > (define-key org-capture-mode-map "\C-c\C-c" 'org-ctrl-c-ctrl-c)) > (add-hook 'org-capture-mode-hook 'ngz-org-capture-hook-handler) > > to my config file. I'm pretty happy with it. > > One solution would be to have C-x C-s (or some other binding, I don't > really mind) calling `org-finish-function' instead of the very busy C-c > C-c. > > C-x C-s makes sense as Log buffers are not attached to any file, so > `save-buffer' is morally equivalent to C-x C-w, aka `write-file'. > > Fellow Orgers, WDYT? On the master branch, I'd be in favor of making a separate command for calling org-finish-function and binding it to C-x C-s. I'd also be OK with changing org-capture-finalize's binding to C-x C-s. On maint, can this issue be solved by just removing the prefix argument check from org-store-log-note? AFAICS, the prefix argument behavior isn't documented anywhere, and the same behavior is already available through org-kill-note-or-show-branches (C-c C-k). -- Kyle