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

"Include" filter to add only those entries that match regex #89

Closed
romangr opened this issue Apr 23, 2022 · 1 comment · Fixed by #92
Closed

"Include" filter to add only those entries that match regex #89

romangr opened this issue Apr 23, 2022 · 1 comment · Fixed by #92

Comments

@romangr
Copy link
Contributor

romangr commented Apr 23, 2022

I have a use-case when there are a lot of videos on the channel but only some of them are relevant for my feed.
These videos are not in a separate playlist so it's not possible to use playlist-based feed.
Is it reasonable to add "include" filter as an alternative to the existing "skip" filter?

@umputun
Copy link
Owner

umputun commented Apr 23, 2022

this is a valid use case for sure. However, adding an "include" regex to feed settings to address youtube's side filtering may not be the best idea. In this case, yt part won't have a clue about filtering and will download, process, and store potentially useless episodes.

The better solution will be to add a "filter" parameter to youtube.channels. I think it may have both "include" and exclude elements, smth like this

 channels:
  - {id: UCWAIvx2yYLK_xTYD4F2mUNw, name: "Живой Гвоздь", lang: "ru-ru", keep: 5, filter:{include:"Особое мнение", exclude: "Леонид Радзиховский"}
}

In this case, we will download and store only those episodes matching include regex and at the same time, non-matching exclude. All we need to do is a couple of matches into youtube.service code to put those mismatched items to ignored.

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 a pull request may close this issue.

2 participants