Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add date-based entry filtering rules #3016

Merged
merged 3 commits into from
Dec 17, 2024

Conversation

Sevichecc
Copy link
Contributor

@Sevichecc Sevichecc commented Dec 16, 2024

Do you follow the guidelines?


Description

Add support for filtering entries by date using block and keep rules. This allows users to filter out future entries or entries within specific date ranges. Replace the previous PR #2976.

New Features

  • Add EntryDate field to entry filtering rules
  • Support the following date patterns:
    • future - Block or allow entries with future dates
    • before:YYYY-MM-DD - Filter entries before a specific date
    • after:YYYY-MM-DD - Filter entries after a specific date
    • between:YYYY-MM-DD,YYYY-MM-DD - Filter entries between two dates

Example Usage

Block rules:

EntryDate=future
EntryDate=before:2024-01-01

Keep rules:

EntryDate=between:2024-01-01,2024-12-31
EntryDate=after:2024-03-01

Changes

  • Add EntryDate to valid field names in validator
  • Add date pattern validation
  • Add date matching logic in entry processor
  • Add tests for date-based filtering

Relative Issue

Fixed #2971

@fguillot fguillot merged commit bca9bea into miniflux:main Dec 17, 2024
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Option to Filter Out Future-Dated Entries
2 participants