Skip to content

Conversation

albertodonato
Copy link
Contributor

@albertodonato albertodonato commented May 23, 2025

ENG-5168

what

  • add copywrite setup to generate headers
  • add license headers to all files
  • check in CI that all fields have a header

why

ensure copyright is set on all files

testing

added CI check

docs

n/a

@albertodonato albertodonato marked this pull request as ready for review May 23, 2025 13:53
@albertodonato albertodonato requested a review from a team as a code owner May 23, 2025 13:53
@albertodonato
Copy link
Contributor Author

The first commit has the actual changes, the rest is autogenerated by running just copyright

@jtroup
Copy link

jtroup commented May 23, 2025

@albertodonato elsewhere this looks like this:

# Copyright © 2025 Stacklet, Inc. All rights reserved.

I think at the very least I'd like to see a) the year and b) 'Stacklet, Inc.' as are formal name, if it's possible with the tool you're using?

@albertodonato albertodonato force-pushed the ack/add-license branch 3 times, most recently from bcc08c3 to da6f185 Compare May 26, 2025 16:19
Copy link
Contributor

@fwereade fwereade left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like we clearly will need a license, and I'm suspicious about the lack of year in the generated headers, but I'm happy with the infrastructure for generating them, so LGTM as a capability, I just wouldn't want to release like this ;).

@albertodonato
Copy link
Contributor Author

albertodonato commented May 27, 2025

@jtroup @fwereade thanks for the review.

It seems copywrite doesn't support having the year directly (I'm actually not sure what the value in the config is used for), but looking at this it seems one option is to add it in the copyright holder string.

The hashicorp sample provider has this:

// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: MPL-2.0

Alternatively there's addlicense (mentioned in the bug above), which gives me something like this:

// Copyright 2025 Stacklet Inc.
// SPDX-License-Identifier: proprietary

(technically proprietary is not a valid SPDX identifier but there isn't one for non-opensource licenses).

It still doesn't seem to support updating headers once they're there, but maybe it's a better solution given copywright limitations

@albertodonato albertodonato marked this pull request as draft May 27, 2025 10:20
@albertodonato albertodonato force-pushed the ack/add-license branch 2 times, most recently from c58a9b5 to f03a843 Compare May 27, 2025 13:06
@albertodonato albertodonato marked this pull request as ready for review May 27, 2025 13:11
@albertodonato albertodonato force-pushed the ack/add-license branch 3 times, most recently from 2af1ed9 to 8c26792 Compare May 27, 2025 13:14
[ENG-5168](https://stacklet.atlassian.net/browse/ENG-5168)

### what

- add copywrite setup to generate headers
- add license headers to all files
- check in CI that all fiels have a header

### why

ensure copyright is set on all files

### testing

added CI check

### docs

n/a
@albertodonato albertodonato merged commit ef968be into main May 27, 2025
6 checks passed
@albertodonato albertodonato deleted the ack/add-license branch May 27, 2025 13:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants