It does extremely useful things like execute sendmail and spew dubiously
accurate factoids.
From the feedback, it seems like it is an essential utility in a modern unix
and not at all a useless bikeshed. How do those Linux people live without it?
Reverts r358561.
Mainly focus on files that use BSD 3-Clause license.
The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.
Special thanks to Wind River for providing access to "The Duke of
Highlander" tool: an older (2014) run over FreeBSD tree was useful as a
starting point.
Renumber cluase 4 to 3, per what everybody else did when BSD granted
them permission to remove clause 3. My insistance on keeping the same
numbering for legal reasons is too pedantic, so give up on that point.
Submitted by: Jan Schaumann <jschauma@stevens.edu>
Pull Request: https://github.com/freebsd/freebsd/pull/96
In addition to adding `static' where possible:
- bin/date: Move `retval' into extern.h to make it visible to date.c.
- bin/ed: Move globally used variables into ed.h.
- sbin/camcontrol: Move `verbose' into camcontrol.h and fix shadow warnings.
- usr.bin/calendar: Remove unneeded variables.
- usr.bin/chat: Make `line' local instead of global.
- usr.bin/elfdump: Comment out unneeded function.
- usr.bin/rlogin: Use _Noreturn instead of __dead2.
- usr.bin/tset: Pull `Ospeed' into extern.h.
- usr.sbin/mfiutil: Put global variables in mfiutil.h.
- usr.sbin/pkg: Remove unused `os_corres'.
- usr.sbin/quotaon, usr.sbin/repquota: Remove unused `qfname'.
- Remove the 3rd clause of the UC Berkeley copyrighted files.
- For the files added copyrighted by me, move the "All rights
reserved" to the next line.
- Repeating events which span multiple years (because of -A, -B or
just the three days before the end of the year).
- Support for lunar events (full moon, new moon) and solar events
(equinox and solstice, chinese new year). Because of this, the
options -U (UTC offset) and -l (longitude) are available to
compensate if reality doesn't match the calculated values.
MFC after: 1 month
Correct long-standing off-by-one error in -W option.
Submitted by: edwin@
Shorten some long lines. These files are still not completely
style(9) compliant.
style "every Monday":
mon * Do Foo.
Previously, at the end of the month, this could cause a printout of
the following nature when invoked with -A 7:
36 May* Do Foo
MFC after: 2 weeks
-W is like -A (number of days in the future to consider, but also
specifies that we don't want special treatment at weekends.
-F changes our notion of "Friday" (the day before the weekend).
Arguably, calendar(1) is broken to have special treatment of weekends
by default, but this method maintains POLA.
of the recent WARNS commits. The idea is:
1) FreeBSD id tags should follow vendor tags.
2) Vendor tags should not be compiled (though copyrights probably should).
3) There should be no blank line between including cdefs and __FBSDIF.
Remove some whitespace
Fix a problem where any event on the Last whatever of the month
was duplicated after the last day of the month (e.g. 32oct.)
PR: 4907
Submitted by: Mikhail Teterin mi@aldan.algebra.com
plain 0 should be used. This happens to work because we #define
NULL to 0, but is stylistically wrong and can cause problems
for people trying to port bits of code to other environments.
PR: 2752
Submitted by: Arne Henrik Juul <arnej@imf.unit.no>
Jan 1st (and probably other dates as well) for some variable
events. E.g.
01/SunThird whatever...
Was being printed as:
Jan 0 Whatever
when calendar was run on January 1st.
Closes PR#2461.
calendar -t 0101 -f file
Previously calendar's time processing routine directly
modified the "0101" argument" which confused getopt.
The time routines now make a copy of the argument
to mess with.
E.g. for Easter, and entries like "04/SunFirst" calendar will
now report:
04/05* Good Friday (2 days before easter)
04/07* First Sunday...
instead of:
Easter-2 Good Friday...
04/SunFirst First Sunday...
I also modified the calendar files to use the variable day format
for a lot of events so that they will be reported correctly.
E.g. U.S. daylight savings time is now listed as:
04/SunFirst Daylight savings time...
There are still a lot of wrong dates in there for some events
that move from year to year, but I don't have a good calendar handy
right now that I can use for reference.
``the last Monday in April'
- handle easter
new options
-f calendarfile
-A days
-B days
Calendar HOME directory ~/.calendar
don't sent mail if ~/.calendar/nomail exist