Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copyright line should append after the SPDX identifier #131

Open
Dentrax opened this issue Nov 19, 2022 · 3 comments
Open

Copyright line should append after the SPDX identifier #131

Dentrax opened this issue Nov 19, 2022 · 3 comments

Comments

@Dentrax
Copy link

Dentrax commented Nov 19, 2022

I just tried SPDX flag first time and noticed addlicense adds copyright line before the SPDX identifier.

$ addlicense -s=only -c Furkan .

Actual:

Copyright ...
SPDX-License-Identifier:

My expectation according to other open source projects, solidity, etc.:

SPDX-License-Identifier:
Copyright ...

Any ways to reorder of those? Shouldn't the right way is the bottom one?

@willnorris
Copy link
Collaborator

I don't think there is a "right way". I've always listed copyright first, since that is how non-SPDX license declarations nearly always appear. I've never paid much attention to how others do it. I think it should be trivial to reverse using a custom license template?

@willnorris
Copy link
Collaborator

willnorris commented Nov 19, 2022

also regarding any "right way", unfortunately the SPDX docs only talk about the SPDX line itself, nothing about where it falls in relation to other information: https://spdx.dev/ids/

Though they do have a few additional links:

So, there does not seem to be consensus, but most seem to list copyright first. I wonder if linux has SPDX first because they added it to most files after the fact, and it's much easier to automate simply adding it as the first line of files. This looks to be the main commit where that happened.

@Dentrax
Copy link
Author

Dentrax commented Nov 19, 2022

Thanks for the prompt response and the references! I think passing a custom license template would better in this case, as you said.

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

No branches or pull requests

2 participants