4

Following the SPDX simple license expressions and the License identifier field example, when creating a custom license that's not listed in licenses list (including exception), I could use LicenseRef-ACME, where ACME is my company name, or even, my project name in a repository.

However, when having to extract a license text from a header, to distribute that custom license as a separated file, I'm not sure about:

  • The license name that should be used (e.g. LicenseRef-ProjectName)
  • The license file name that should be used (e.g. LICENSE)
  • Custom fields in the license file to refer where I extract that text.

I read about DocumentRef, but I'm not sure if it's the case, and how to use it.

1 Answer 1

4

I use reuse to validate my SPDXing and it's happy with the following:

  1. Using LicenseRef-ProjectName. Unless your work is owned by a company and you're planning on using the same license for all your projects, in which case LicenseRef-CompanyName will indicate that to your customers.

  2. I create LICENSES/LicenseRef-ProjectName.txt (reuse requires a copy of each license in the LICENSES folder).

  3. No custom fields are required. The license file should be just the license text.

Then in a file using that license I use:

# SPDX-License-Identifier: LicenseRef-ProjectName
# SPDX-FileCopyrightText: Copyright 2023 A. P. Hacker

Using a validator and simply following their guidelines can take some of the administrative burden off your shoulders.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.