History log of /freebsd-current/usr.bin/calendar/events.c
Revision Date Author Comments
# 1d386b48 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: one-line .c pattern

Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/


# 4d846d26 10-May-2023 Warner Losh <imp@FreeBSD.org>

spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD

The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch
up to that fact and revert to their recommended match of BSD-2-Clause.

Discussed with: pfg
MFC After: 3 days
Sponsored by: Netflix


# d87cb51f 13-Dec-2020 Stefan Eßer <se@FreeBSD.org>

Fix WITHOUT_ICONV build

Move the include of langinfo.h out of the WITH_ICONV condition block,
since it is not dependent on ICONV. This was correct when nl_langinfo()
had only been called in the WITH_ICONV case, but that is no longer the
case.

Submitted by: yuripv


# 8a428dfe 13-Dec-2020 Stefan Eßer <se@FreeBSD.org>

Revert r368606

The issue will be fixed in a different way.

Reported by: yuripv


# c6e0073a 13-Dec-2020 Stefan Eßer <se@FreeBSD.org>

Fix WITHOUT_ICONV build

There was an unprotected use of nl_langinfo() to determine the order of
day vs. month in the generated output.

When building without ICONV support, the order will be: month, day.


# 0357fa26 05-Nov-2020 Stefan Eßer <se@FreeBSD.org>

Restrict locale settings to the file they occur in

This prevents LANG= in an included file from affecting the interpretation
of month and day names in the including file.

Make the internal pre-processor accept white space between the "#" at
the start of the line and the keyword for better compatibility with cpp.

Add support for the cpp keywords #warning and #error.

MFC after: 3 days


# 2ceb17a8 04-Nov-2020 Stefan Eßer <se@FreeBSD.org>

Add regression tests for conditions and comments

Fix one case where #else was not corerctly processed and simplify the
conditions logic.

Fix parsing of day and month names in the locale specified in the calendar
file. The previous version would expect those names to match the locale of
the user.

Mention that comments are now correctly processed and that // is supported
in addition to /* ... */.

MFC after: 3 days


# cb895863 30-Oct-2020 Stefan Eßer <se@FreeBSD.org>

Revert debug output committed in r367166 by accident

MFC after: 3 days


# 6bdb89a8 30-Oct-2020 Stefan Eßer <se@FreeBSD.org>

Fix length calculation in memmove

MFC after: 3 days


# ac04cf18 29-Oct-2020 Stefan Eßer <se@FreeBSD.org>

Simplify test for closing delimiter of #include argument (no functional
change).

While here: Fix invalid parameters of a commented-out debug printf() found
when testing with this code enabled.

MFC after: 3 days


# fd1efedc 02-Mar-2020 Conrad Meyer <cem@FreeBSD.org>

Add extremely useful calendar(1) application to FreeBSD

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.


# 3c565de3 02-Mar-2020 Conrad Meyer <cem@FreeBSD.org>

Fix typo in r278616

FreeBSD isn't an encyclopedia.


# adedf5ee 19-Feb-2019 Baptiste Daroussin <bapt@FreeBSD.org>

calendar: use iconv to respect the output encoding

calendar(1) can have input in various encoding, specifying
LANG=<locale_name> to enable calendar(1) to determine which one to use.

The problem is the content of the calendar itself is exposed as is making it
unreadable in many cases. For example french calendar which is encoded
ISO8859-1 is rendered badly in a fr_FR.UTF-8 environment.

Using iconv allows to solve this issue.
This will also allow to keep only 1 encoding in base for those files without
breaking user existing setup

Reported by: many
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D19221


# 1de7b4b8 27-Nov-2017 Pedro F. Giffuni <pfg@FreeBSD.org>

various: general adoption of SPDX licensing ID tags.

Mainly focus on files that use BSD 2-Clause license, however the tool I
was using misidentified many licenses so this was mostly a manual - error
prone - task.

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.

No functional change intended.


# 65d4f317 26-Sep-2017 Baptiste Daroussin <bapt@FreeBSD.org>

calendar: replace strcpy/strcat with asprintf


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# bb06482c 30-Mar-2010 Edwin Groothuis <edwin@FreeBSD.org>

On request of joel@:

- 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.


# 2b84020d 29-Mar-2010 Edwin Groothuis <edwin@FreeBSD.org>

Long awaited update to the calendar system:

- 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