Kristoffer Balintona <krisbalint...@gmail.com> writes: > Thank you for the help. I've attached a diff for a set of proposed > changes. It has `org-capture-expand-olp' and > `org-capture-expand-headline' return the symbol 'file in certain cases > and has `org-capture-set-target-location' treat those cases specially, > inserting the capture entry at the top level. Additionally, I updated > the docstring of `org-capture-templates' appropriately and added an > additional test in `test-org-capture/org-capture-expand-olp'.
Why not just using nil value as you initially suggested? > ... Although I've never contributed to org before, so I will > have to read up on the conventions for patches. See https://orgmode.org/worg/org-contribute.html#patches > A separate matter: > I find it unusual that we have the file+olp and file target > specifications but not a file+datetree target specification. As a > result, file+olp+datetree accepts a nil olp to insert the datetree on > the top level but file+olp does not because that would just be > equivalent to the file target specification. I feel like we should > either add one or do something like removing the file specification and > having file+olp cover its case. We used to have file+datetree target, and a number of others. They have been consolidated into a single file+olp+datetree in Org 9.1, 8 years ago. See https://list.orgmode.org/orgmode/CADn3Z2+AanLPvUO9ENhZ_2tkAvsmdnq9ewR3sFasn=zv--s...@mail.gmail.com/ -- Ihor Radchenko // yantar92, Org mode maintainer, Learn more about Org mode at <https://orgmode.org/>. Support Org development at <https://liberapay.com/org-mode>, or support my work at <https://liberapay.com/yantar92>