Skip to content
This repository was archived by the owner on Oct 15, 2025. It is now read-only.

improve gnu units output parsing#91

Closed
iyzana wants to merge 4 commits intoalbertlauncher:devfrom
iyzana:improve-units-output
Closed

improve gnu units output parsing#91
iyzana wants to merge 4 commits intoalbertlauncher:devfrom
iyzana:improve-units-output

Conversation

@iyzana
Copy link
Copy Markdown
Contributor

@iyzana iyzana commented Nov 10, 2020

units 500seconds time is currently giving output like this 0;0;0;8;20 which is not very human friendly
this PR changes the output to 8 min + 20 sec

i believe the other outputs are unchanged:
units 5min => 300 s
units 1foot cm => 30.48

also, giving negative inputs is now supported, as units interpreted them as flags before

@iyzana iyzana changed the base branch from master to dev November 10, 2020 01:55
@ManuelSchneid3r
Copy link
Copy Markdown
Member

ManuelSchneid3r commented Nov 10, 2020

units 500seconds time is currently giving output like this 0;0;0;8;20

~ gunits 500seconds time
	8 min + 20 sec

Whats the problem?

@iyzana
Copy link
Copy Markdown
Contributor Author

iyzana commented Nov 10, 2020

the plugin runs units with the --terse flag, in order to get parsable output for most other queries (e.g. units 500seconds hour).
but in terse mode the unit list output is semicolon-seperated.

@ManuelSchneid3r ManuelSchneid3r deleted the branch albertlauncher:dev November 23, 2020 20:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants