Function: erc--read-time-period

erc--read-time-period is a byte-compiled function defined in erc.el.gz.

Signature

(erc--read-time-period PROMPT)

Documentation

Read a time period on the "2h" format.

If there's no letter spec, the input is interpreted as a number of seconds.

If input is blank, this function returns nil. Otherwise it returns the time spec converted to a number of seconds.

Source Code

;; Defined in /usr/src/emacs/lisp/erc/erc.el.gz
(defun erc--read-time-period (prompt)
  "Read a time period on the \"2h\" format.
If there's no letter spec, the input is interpreted as a number of seconds.

If input is blank, this function returns nil.  Otherwise it
returns the time spec converted to a number of seconds."
  (erc--decode-time-period
   (string-trim (read-string prompt nil 'erc--read-time-period-history))))