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

parse_timespan: add support for an "abbreviated" output #39

Open
sandrotosi opened this issue Mar 16, 2020 · 1 comment
Open

parse_timespan: add support for an "abbreviated" output #39

sandrotosi opened this issue Mar 16, 2020 · 1 comment

Comments

@sandrotosi
Copy link

sandrotosi commented Mar 16, 2020

In [52]: humanfriendly.format_timespan(2576)
Out[52]: '42 minutes and 56 seconds'

it would be great if an abbreviated=True argument was present to produce:

In [52]: humanfriendly.format_timespan(2576, abbreviated=True)
Out[52]: '42m 56s'

parse_timespan accepts that shortened version already.

thanks!

@fsaintjacques
Copy link
Contributor

That would be format_timestamp. I'd like to have this too.

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

No branches or pull requests

2 participants