Skip to content

Document how years in copyright statements should be presented #128

Description

@ForNeVeR

The current version of the REUSE specification, v3.3, states the following:

The year of publication MAY be a single year, multiple years, or a span of years.

And that's basically the whole normative section, as I read it, that's it.

There are several very useful examples that seem to explain what are "year, multiple years, or a span of years":

SPDX-FileCopyrightText: 2019 Jane Doe <jane@example.com>
Copyright 2016, 2018-2019 Joe Anybody

They seem to suggest that, you guess it, there are groups of years separated by commas ,, and years in spans are separated with the dash -. Which is great.

Could we have more detailed spec on these? E.g. can other group and span separators be used? Also, while technically I guess the notation 2016, 2018-2019 corresponds to the words "multiple years" from the spec, if we read the spec strictly, then it doesn't explicitly say that a combination of "multiple years" and "a span of years" is allowed. Even though it makes sense and should probably be allowed.

Also, I've seen examples in the wild where people used variations of dashes (en dash or em dash ) in their copyright statements — should this be allowed? Perhaps? Because it makes sense and is typographically correct?

(One such random example is here, even though not meant for REUSE specifically — but that's a proof that people use statements like this.)

Anyway, I'd propose to adjust the definition: first, replace "year" with "years", and then allow for something along the lines of the following grammar:

years = year-element [ year-element-separator years ]
year-element = year-span | year
year = \d+
year-span = year year-span-separator year
year-element-separator = ','
year-span-separator = '-' | '' | ''

(we can of course write it in English words if needed, use of this BNF-like notation is not required)

Additionally, all the entries can be separated by any amount of (optional) whitespace, so that we consume both 1997-1998 and 1997 - 1998 (in case of inaccurate formatting).

So, we allow spans to be separated with either of three dashes, and require the spans or singular years to be separated with comma, while allowing any combination of them in a single "years" fragment.

What do you think? Does it make sense? Or perhaps it was designed with more lax definition of "years" in mind?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions