Is it possible to compare a post's date to now?

I’ve been using the Archive code

{% for year, posts in section.pages | group_by(attribute="year") %}
    <h2>{{ year }}</h2>

    {% for post in posts %}
        <li><a href="{{ post.permalink }}">{{ post.title }}</a></li>
    {% endfor %}
{% endfor %}

to list the blog posts I’ve written and it works great.

However, now I want to filter out posts that are post-dated (having a date property in the future). This way I could do scheduled releases without having to use draft and redeploying.

Any ideas?

I did not find anything more straightforward than this:

{% for page in section.pages %}
	{% if %}
		{% set page_time =|date(format="%s")|int %}
		{% set curr_time = now()|date(format="%s")|int %}
		{% if page_time < curr_time %}
		Hello from the past
		{% else %}
		Hello from the future
		{% endif %}
	{% endif %}
{% endor %}

But it works.

Probably the only way to do it currently yes