Brief parameter for humanize function
Feature Request
This parameter is False by default. When true, it shortens the date and time terms. For example:
>>> present = arrow.utcnow()
>>> shift = present.shift(hours=2, minutes=34, seconds=56)
>>> shift.humanize(present, brief=True, only_distance=True)
>>> 2h 34m 56s
I think this is a nice feature to add. Only issue I see is the fact it needs to be supported by multiple locales.
Only issue I see is the fact it needs to be supported by multiple locales.
Yes, this is a issue.
@jadchaar @systemcatch @krisfremen what do we think? I would prefer we have at least 10 locales that can support this feature before we implement it.
I like it, but would some locales not have shortened forms?
Hi! @akotha7 and I would like to work on this. We aim to have the functionality supported by at least 5 locales for now. Please let us know if there is anything we should know.
Hi @neelrpatel, I think for this kind of work we need a spec detailing how this will work and what locales will be supported. i.e. expected inputs and outputs, how locales that don't support this respond.
Hi @systemcatch and @anishnya! I've put up a PR for this issue. I added tests and documentation as well, and would love feedback on locales and edge cases I mentioned in the PR.