Smarter trim_feed handling

Keep at least 500 articles or 180 days worth of articles per feed,
whichever is greater.