Function: calendar-day-of-year-string

calendar-day-of-year-string is a byte-compiled function defined in calendar.el.gz.

Signature

(calendar-day-of-year-string &optional DATE)

Documentation

String of day number of year of Gregorian DATE.

Defaults to today's date if DATE is not given.

Source Code

;; Defined in /usr/src/emacs/lisp/calendar/calendar.el.gz
(defun calendar-day-of-year-string (&optional date)
  "String of day number of year of Gregorian DATE.
Defaults to today's date if DATE is not given."
  (let* ((d (or date (calendar-current-date)))
         (year (calendar-extract-year d))
         (day (calendar-day-number d))
         (days-remaining (- (calendar-day-number (list 12 31 year)) day)))
    (format "Day %d of %d; %d day%s remaining in the year"
            day year days-remaining (if (= days-remaining 1) "" "s"))))