Skip to content

feat(capture): Support for "prepend" as field in capture templates #1159

Open
freddrH wants to merge 5 commits into
nvim-orgmode:masterfrom
freddrH:feat/prepend_in_capture_template
Open

feat(capture): Support for "prepend" as field in capture templates #1159
freddrH wants to merge 5 commits into
nvim-orgmode:masterfrom
freddrH:feat/prepend_in_capture_template

Conversation

@freddrH

@freddrH freddrH commented Jun 11, 2026

Copy link
Copy Markdown

Summary

In emacs orgmode capture templates can have the property ":prepend". By default captured items are places as the last child (last headline, sub-headline, etc) at the destination. By setting prepend captured items are prepended (placed as the first item at the target) .

Been working with a hack in capture/init.lua locally to have this feature for all templates for myself. Now added the feature to set it in the capture template, as it should be.

Related Issues

Related #

Closes #

Changes

  • Added field to capture templates
  • target_headline can now have two different outcomes (first and last)

Checklist

I confirm that I have:

  • Followed the
    Conventional Commits
    specification
    (e.g., feat: add new feature, fix: correct bug,
    docs: update documentation).
  • My PR title also follows the conventional commits specification.
  • Updated relevant documentation, if necessary.
    (starting here as discussed)
  • Thoroughly tested my changes.
  • Added tests (if applicable) and verified existing tests pass with
    make test.
    (starting here as per discussed, not savvy with testing, looking for pointer)
  • Checked for breaking changes and documented them, if any.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants