jnoortheen / xontrib-cmd-durations

Show long running commands durations in prompt with option to send notification when terminal is not focused.
MIT License
16 stars 4 forks source link

fix(timeout): cast to numeric if user provides custom duration #18

Closed gforsyth closed 3 months ago

gforsyth commented 3 months ago

If a user sets a custom duration timeout, since the value gets pulled from the environment and isn't detyped, it comes in as a string and then breaks because of a > comparison between a number and a string.

In the long run, probably good to add proper detyping, but for now, this makes things not break.

jnoortheen commented 3 months ago

Thanks @gforsyth !