Sam Mayer
Sam Mayer
This guide is a great starting point for documentation: https://strdr4605.com/commitlint-custom-commit-message-with-emojis
[This guide](https://strdr4605.com/commitlint-custom-commit-message-with-emojis), by strdr4605 is a great starting point for how to write a custom parser. Cross-references in #3336 as something to reference while documenting `parserOpts` and `headerPattern`.
I'm looking at this in my free time. Looks like a solution *could* be an extra optional parameter in `format_timedelta()` within `dates.py`.
I think there's probably a good recursive solution to this. [Here's my fork](https://github.com/samayer12/babel/tree/728_timedelta_granularity)
[My first crack](https://github.com/samayer12/babel/commit/dd732b416631a04f79d025354f266c04c7f067fa) at the problem can produce some of your desired output. Check out `test_format_four_units()` in `test_dates.py`. However, it doesn't handle instances where the granularity is before the base...
Alright, [this commit](https://github.com/samayer12/babel/commit/29e4f8d2376448845bd6660514d99a0315102e94) does everything you asked for. Gotta refactor it.
^^^ No it definitely does not lol. Still working on my fork. Handling the case where you have granularity of seconds but say, just one week. Aside from that, I...