Define maximum number of revisions per post type?

How can I define the maximum number of revisions on a per-post type basis?

For example posts have 3 max revisions where as pages have a max of 10.

Related posts

Leave a Reply

1 comment

  1. I might be wrong, but my first guess would be that this is not easily possible, because number of revisions gets saved into constant and does not seem hook-able.

    From quick search relevant checks are in wp_save_post_revision() and it’s very rigid.