Skip to content
Merged
Prev Previous commit
Next Next commit
feat(cli): improve long duration testing and negative values
  • Loading branch information
defelmnq committed Oct 14, 2024
commit 256c085b9df7ac5ed14fa573c3afe8c6ba01c6e6
4 changes: 2 additions & 2 deletions cli/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -185,8 +185,8 @@ func isDigit(s string) bool {
// extendedParseDuration is a more lenient version of parseDuration that allows
// for more flexible input formats and cumulative durations.
// It allows for some extra units:
// - d (days)
// - y (years)
// - d (days, interpreted as 24h)
// - y (years, interpreted as 8_760h)
//
// FIXME: handle fractional values as discussed in https://github.com/coder/coder/pull/15040#discussion_r1799261736
func extendedParseDuration(raw string) (time.Duration, error) {
Expand Down
Loading