From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id yI/yHrYBnmc4pwAAe85BDQ:P1 (envelope-from ) for ; Sat, 01 Feb 2025 11:12:54 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id yI/yHrYBnmc4pwAAe85BDQ (envelope-from ) for ; Sat, 01 Feb 2025 12:12:54 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=cas.cat header.s=2023 header.b=vvO33ISj; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1738408374; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=g+81ADtbg2mMG4aWyWdWPCxtwIK2XUX3ktbdXtnEjl4=; b=SSFYxSpuhhHnJe1kLfHJPZVhb9Uoed4Y147Ixw2MtgQmfdzKbyxJPEoF0JX1AFt4SMSYbL jWeTJ7UMxLmKhxlOrvnjxyWOQI7iUdlOPMNKrxDpXUsjvfMuL9C4FQxsAh6+cMg7PSI3gs Y/Z4BXsonhn7ilMy3ukJqNpB57iUADz2Ww2X/LjUDOwIxNNkk3Gk++C2mgNujylgrtD7/8 jwlXYCHSYStq5r+W0nMjw6ttSU7eegZazir0OsLNE7zQ+xMiMN462x/4ah3UVFLVWpv4zA FTCGnxr3DdmLUTVAKmHxwnY4rIJ6lt0vJB/x9iH09kEnoJeT6kbQHsxz9pTJFw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=cas.cat header.s=2023 header.b=vvO33ISj; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1738408374; a=rsa-sha256; cv=none; b=P1L3QSKmV58EU0rT6Zmjk1903KlfbHrdSwsyuBzg64yP3rB6Yj1Vmg3upvnIFXTGYFb3ho EoDm5Yd/dokaCzgPJW5CHnwHbudpUWAjJfuS2Gnw8N71RG1oiuKhb51HnJII1WR3VrMz45 kH0V0qHloybcJln9nk/I+9g7QE4JUQSbNkWjdSDPDLmluFVRsAC8zBVsnMsErMldZHD/px WgkcZ08YbmVk0lnmjq6Tc6axEEJ3efNR96E/qh7V8nTR/rg85Q65nZD+SCtvkj9crtLPW7 SFWvHo+OlYrqu7Ao0FXROWNviSnYSAj5hy3jMYIzULzgtapFuucOQd5+oR5d0A== 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 2385F83898 for ; Sat, 01 Feb 2025 12:12:54 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1teBPm-000172-Bg; Sat, 01 Feb 2025 06:11:54 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1teBPh-00016i-NU for emacs-orgmode@gnu.org; Sat, 01 Feb 2025 06:11:50 -0500 Received: from cas.cat ([45.150.187.15]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1teBPf-0001Mp-6Q for emacs-orgmode@gnu.org; Sat, 01 Feb 2025 06:11:49 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cas.cat; s=2023; t=1738408298; bh=SpK3El8LT9xP7IJ9jjfQ3PQqJOlPQO94kif/OkZdM+s=; h=Date:Subject:To:References:From:In-Reply-To:From; b=vvO33ISj/A0ONhoLFdcros5DIvTYfqUx+GZPx3JkMnAScDSKDAPqYf+tIa8C7JcVk DiJDiO0wOkWKdusHdzBpY0yOrd/sPajH0W7mo7+3JLL0ss0dT3BEDSFB2MKlTq0BZ+ gyYMzsHITcBUTNWKzwYGzdH+EZyQ6lr64GxBf5IJr6grRDlgBs+ujb0l4mkVM7cLv0 hbUHVWbd5+q3J2S/Zsd+R9KhxHFkQ9PU2AHYkoSpurftu+wavXHVrNFu73Yol7t+Sp XJNTXv1Dp+SfDN2+0X1Yv2B4HIY+S7XTDP73Gx/noEkVxjv+Ics7WaGHS939VNW9lP ODBzBDr+qiq5A== Content-Type: multipart/mixed; boundary="------------kjwbmepBZrySxTD1SptKHGES" Message-ID: Date: Sat, 1 Feb 2025 12:11:38 +0100 MIME-Version: 1.0 Subject: Re: insert a header and automatically a timestamp with date/time To: emacs-orgmode@gnu.org References: <87seoy3xqg.fsf@mat.ucm.es> Content-Language: en-US In-Reply-To: <87seoy3xqg.fsf@mat.ucm.es> Received-SPF: pass client-ip=45.150.187.15; envelope-from=pinmacs@cas.cat; helo=cas.cat X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 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, HTML_MESSAGE=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_PASS=-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.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: pinmacs From: pinmacs via "General discussions about Org-mode." Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -2.83 X-Spam-Score: -2.83 X-Migadu-Queue-Id: 2385F83898 X-Migadu-Scanner: mx11.migadu.com X-TUID: HJ9ZfYF8sdiF This is a multi-part message in MIME format. --------------kjwbmepBZrySxTD1SptKHGES Content-Type: multipart/alternative; boundary="------------G366bKAOIX4eafRoZAT6WgR1" --------------G366bKAOIX4eafRoZAT6WgR1 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 2025-02-01 08:55, Uwe Brauer via General discussions about Org-mode. wrote: > Is there any way to insert a header and automatically a timestamp with > date/time? > > I can write me a small function doing this and bind it to some unused > key, but is there a more general/elegant way I just miss? Hi Uwe, TL DR; I add the timestamp automatically on entry creation as a hook [2], in fact, I have several hooks on entry creation and I think is a good way to handle this. I am happy with my setup since I started using it in 2023. Let me share my experience on that topic (and very happy to hear other experiences and/or feedback), I hope the offtopic inside is welcome and useful: 1. Before, I was manually adding timestamp headers as a postfix for the creation of the header (and this is how I reverted using this script per target buffer [1]) to transform to CREATED properties (see here the automation on how I add the timestamp automatically on entry creation [2]), which I think are even better, specially, because then you can add that column to your table-reports such as clocktable, org-ql, propview, custom org-map-entries stuff. 2. After, as a prefix, in the journal files, for facilitating alphanumeric sorting of items in my customized journal (with a structure of year > week > day). I finally got rid of that, and brain and eyes appreciated that movement, it is too much noise to see a lot of items with timestamp. I discovered that problem when I started using variable-pitch mode, which with modes themes works very nice with (enable variable: (setq modus-themes-mixed-fonts t) ). Then, alternatively, sorting can be done by adding "SCHEDULED" to all items created on certain buffers and levels [3], which I also add for certain org-agenda files (then I use schedule as a poor's man alternative to anki [4] for space repetition [5], which could of course involve real tasks and projects apart from the typical usecase of memorizing concepts). I do it this way and it works fine for me since that date I use it: Cheers, pinmacs [1] see attached file: migrate-from-ts-header-to-created-property.org [2] see attached file: auto-insert-created-timestamp-as-property.org [3] see attached file: autoadd-scheduled-entry [4] https://en.wikipedia.org/wiki/Anki_(software) [5] https://en.wikipedia.org/wiki/Spaced_repetition --------------G366bKAOIX4eafRoZAT6WgR1 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit
On 2025-02-01 08:55, Uwe Brauer via General discussions about Org-mode. wrote:
Is there any way to insert a header and automatically a timestamp with
date/time?

I can write me a small function doing this and bind it to some unused
key, but is there a more general/elegant way I just miss?

Hi Uwe,

TL DR; I add the timestamp automatically on entry creation as a hook [2], in fact, I have several hooks on entry creation and I think is a good way to handle this. I am happy with my setup since I started using it in 2023.

Let me share my experience on that topic (and very happy to hear other experiences and/or feedback), I hope the offtopic inside is welcome and useful:

1. Before, I was manually adding timestamp headers as a postfix for the creation of the header (and this is how I reverted using this script per target buffer [1]) to transform to CREATED properties (see here the automation on how I add the timestamp automatically on entry creation [2]), which I think are even better, specially, because then you can add that column to your table-reports such as clocktable, org-ql, propview, custom org-map-entries stuff.
2. After, as a prefix, in the journal files, for facilitating alphanumeric sorting of items in my customized journal (with a structure of year > week > day). I finally got rid of that, and brain and eyes appreciated that movement, it is too much noise to see a lot of items with timestamp. I discovered that problem when I started using variable-pitch mode, which with modes themes works very nice with (enable variable: (setq modus-themes-mixed-fonts t) ). Then, alternatively, sorting can be done by adding "SCHEDULED" to all items created on certain buffers and levels [3], which I also add for certain org-agenda files (then I use schedule as a poor's man alternative to anki [4] for space repetition [5], which could of course involve real tasks and projects apart from the typical usecase of memorizing concepts).

I do it this way and it works fine for me since that date I use it:

Cheers,
pinmacs



[1] see attached file: migrate-from-ts-header-to-created-property.org

[2] see attached file: auto-insert-created-timestamp-as-property.org

[3] see attached file: autoadd-scheduled-entry

[4] https://en.wikipedia.org/wiki/Anki_(software)

[5] https://en.wikipedia.org/wiki/Spaced_repetition
--------------G366bKAOIX4eafRoZAT6WgR1-- --------------kjwbmepBZrySxTD1SptKHGES Content-Type: text/org; charset=UTF-8; name="auto-insert-created-timestamp-as-property.org" Content-Disposition: attachment; filename="auto-insert-created-timestamp-as-property.org" Content-Transfer-Encoding: base64 Kiogb3JnLWluc2VydC1oZWFkaW5nLWhvb2socykgKDcpCjpQUk9QRVJUSUVTOgo6Q1JFQVRF RDogIFsyMDIzLTA0LTI5IFNhdCAxNjowNF0KOkNVU1RPTV9JRDogMjAyMy0wNC0yOV8xNjow NDo0Ny4xNDYxMTMKOkVORDoKCioqKiAxLiBhbHdheXMgYWRkIENSRUFURUQgcHJvcGVydHkK OlBST1BFUlRJRVM6CjpDUkVBVEVEOiAgWzIwMjMtMDQtMjkgU2F0IDE2OjA1XQo6Q1VTVE9N X0lEOiAyMDIzLTA0LTI5XzE2OjA1OjE2LjkzMDk2Ngo6RU5EOgoKIytuYW1lOiBjcmVhdGVk IG9uIFsyMDIzLTA0LTI5IFNhdCAxNjowNjowOV0KIytiZWdpbl9zcmMgZW1hY3MtbGlzcAoo ZGVmdW4gbXkvb3JnLWhlYWRpbmctaW5zZXJ0LWhlYWRpbmctaW5hY3RpdmUtdGltZXN0YW1w ICgpCiAgKHNhdmUtZXhjdXJzaW9uCiAgICA7OyBzcmMgaHR0cHM6Ly9lbWFjcy5zdGFja2V4 Y2hhbmdlLmNvbS9xdWVzdGlvbnMvNzIxNDcvb3JnLW1vZGUtYWRkaW5nLWNyZWF0aW9uLWRh dGUtcHJvcGVydHktdXBvbi1oZWFkaW5nLWNyZWF0aW9uCiAgICAob3JnLWJhY2stdG8taGVh ZGluZykKICAgIChteS9zZXQtcHJvcGVydHktd2l0aC1pbmFjdGl2ZS10aW1lc3RhbXAgIkNS RUFURUQiKSkpCgo7OyBzcmMgaHR0cHM6Ly9lbWFjcy1vcmdtb2RlLmdudS5uYXJraXZlLmNv bS94ZE1JbjVRWi9vLWhvdy1jYW4taS1jYWxjdWxhdGUtdGhlLWFnZS1vZi1hLWhlYWRsaW5l Cjs7IGV4dHJhIHNyYyBodHRwczovL2VtYWNzLnN0YWNrZXhjaGFuZ2UuY29tL3F1ZXN0aW9u cy83MjE0Ny9vcmctbW9kZS1hZGRpbmctY3JlYXRpb24tZGF0ZS1wcm9wZXJ0eS11cG9uLWhl YWRpbmctY3JlYXRpb24KKGFkZC1ob29rICdvcmctaW5zZXJ0LWhlYWRpbmctaG9vayAnbXkv b3JnLWhlYWRpbmctaW5zZXJ0LWhlYWRpbmctaW5hY3RpdmUtdGltZXN0YW1wICdhcHBlbmQp CiMrZW5kX3NyYwoK --------------kjwbmepBZrySxTD1SptKHGES Content-Type: text/org; charset=UTF-8; name="migrate-from-ts-header-to-created-property.org" Content-Disposition: attachment; filename="migrate-from-ts-header-to-created-property.org" Content-Transfer-Encoding: base64 Kiogb3JnLWluc2VydC1oZWFkaW5nLWhvb2socykgKDcpCjpQUk9QRVJUSUVTOgo6Q1JFQVRF RDogIFsyMDIzLTA0LTI5IFNhdCAxNjowNF0KOkNVU1RPTV9JRDogMjAyMy0wNC0yOV8xNjow NDo0Ny4xNDYxMTMKOkVORDoKCioqKiAxLiBhbHdheXMgYWRkIENSRUFURUQgcHJvcGVydHkK OlBST1BFUlRJRVM6CjpDUkVBVEVEOiAgWzIwMjMtMDQtMjkgU2F0IDE2OjA1XQo6Q1VTVE9N X0lEOiAyMDIzLTA0LTI5XzE2OjA1OjE2LjkzMDk2Ngo6RU5EOgoKIytuYW1lOiBjcmVhdGVk IG9uIFsyMDIzLTA0LTI5IFNhdCAxNjowNjowOV0KIytiZWdpbl9zcmMgZW1hY3MtbGlzcAoo ZGVmdW4gbXkvb3JnLWhlYWRpbmctaW5zZXJ0LWhlYWRpbmctaW5hY3RpdmUtdGltZXN0YW1w ICgpCiAgKHNhdmUtZXhjdXJzaW9uCiAgICA7OyBzcmMgaHR0cHM6Ly9lbWFjcy5zdGFja2V4 Y2hhbmdlLmNvbS9xdWVzdGlvbnMvNzIxNDcvb3JnLW1vZGUtYWRkaW5nLWNyZWF0aW9uLWRh dGUtcHJvcGVydHktdXBvbi1oZWFkaW5nLWNyZWF0aW9uCiAgICAob3JnLWJhY2stdG8taGVh ZGluZykKICAgIChteS9zZXQtcHJvcGVydHktd2l0aC1pbmFjdGl2ZS10aW1lc3RhbXAgIkNS RUFURUQiKSkpCgo7OyBzcmMgaHR0cHM6Ly9lbWFjcy1vcmdtb2RlLmdudS5uYXJraXZlLmNv bS94ZE1JbjVRWi9vLWhvdy1jYW4taS1jYWxjdWxhdGUtdGhlLWFnZS1vZi1hLWhlYWRsaW5l Cjs7IGV4dHJhIHNyYyBodHRwczovL2VtYWNzLnN0YWNrZXhjaGFuZ2UuY29tL3F1ZXN0aW9u cy83MjE0Ny9vcmctbW9kZS1hZGRpbmctY3JlYXRpb24tZGF0ZS1wcm9wZXJ0eS11cG9uLWhl YWRpbmctY3JlYXRpb24KKGFkZC1ob29rICdvcmctaW5zZXJ0LWhlYWRpbmctaG9vayAnbXkv b3JnLWhlYWRpbmctaW5zZXJ0LWhlYWRpbmctaW5hY3RpdmUtdGltZXN0YW1wICdhcHBlbmQp CiMrZW5kX3NyYwo= --------------kjwbmepBZrySxTD1SptKHGES Content-Type: text/org; charset=UTF-8; name="autoadd-scheduled-entry.org" Content-Disposition: attachment; filename="autoadd-scheduled-entry.org" Content-Transfer-Encoding: base64 KioqIDQuIGFsd2F5cyBhZGQgU0NIRURVTEVEIHdoZW4gaW4gam91cm5hbCBhbmQgcHJvamVj dCBmaWxlcwo6UFJPUEVSVElFUzoKOkNSRUFURUQ6ICBbMjAyMy0xMS0xNyBGcmkgMTk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ZSBkb24ndCBjYXJlIG9uIGl0cyBjaGlsZHJlbikKICAgICAgICAgICAgKD4gKG9y Zy1jdXJyZW50LWxldmVsKSAzKSkKICAgICAgICkKICAgICAgKHNhdmUtZXhjdXJzaW9uCiAg ICAgICAgOzsgc3JjIGh0dHBzOi8vZW1hY3Muc3RhY2tleGNoYW5nZS5jb20vcXVlc3Rpb25z LzcyMTQ3L29yZy1tb2RlLWFkZGluZy1jcmVhdGlvbi1kYXRlLXByb3BlcnR5LXVwb24taGVh ZGluZy1jcmVhdGlvbgogICAgICAgIDs7KG9yZy1iYWNrLXRvLWhlYWRpbmcpCiAgICAgICAg KG9yZy1zY2hlZHVsZSBuaWwgKGZvcm1hdC10aW1lLXN0cmluZyAiWyVZLSVtLSVkICVhXSIg bmlsKSkpKSkKCihhZGQtaG9vayAnb3JnLWluc2VydC1oZWFkaW5nLWhvb2sgJ215L29yZy1o ZWFkaW5nLWluc2VydC1zY2hlZHVsZWQgJ2FwcGVuZCkKIytlbmRfc3JjCg== --------------kjwbmepBZrySxTD1SptKHGES--