I'm trying to build functions that help me execute frequent sparse tree queries, using
org-match-sparse-tree nil "<some_query>" in my code.
Some of these queries need to contain constraints such as
<end_of_this_month> just means the end of the current month. The same could be true for this week, next week, this year, and so on.
I know about the possibility of writing
SCHEDULED<=<1+y>, but that just means 1 year from now, meaning, as of the time of this writing, from Aug 28 2019 to Aug 27 2020, which is not what I want.
Is there a way to, programmatically, obtain in a string the end of the current or next month/year/week without having to manually calculate those (meaning using a preexisting date-handling function)?